Re: [PATCH -mm] [RFC] IOAT: Add support for version 2 of ioatdma device

Andy Whitcroft
2007-09-07T08:44:01Z

On Thu, Sep 06, 2007 at 10:07:12AM -0700, Shannon Nelson wrote:
> list_for_each_entry(iter, &desc->async_tx.tx_list, node) {
> iter->hw->src_addr = addr;
> addr += ioat_chan->xfercap;
> +
> + if (--cnt == 0);
> + break;
> }
>
> }
> @@ -166,20 +177,28 @@ static void ioat_set_dest(dma_addr_t addr,
> {
> struct ioat_desc_sw *iter, *desc = tx_to_ioat_desc(tx);
> struct ioat_dma_chan *ioat_chan = to_ioat_chan(tx->chan);
> + int cnt = desc->tx_cnt;
>
> pci_unmap_addr_set(desc, dst, addr);
>
> list_for_each_entry(iter, &desc->async_tx.tx_list, node) {
> iter->hw->dst_addr = addr;
> addr += ioat_chan->xfercap;
> +
> + if (--cnt == 0);
> + break;
> }

Those two look suspect to checkpatch, and I have to agree with it.

WARNING: Trailing semicolon indicates no statements, indent implies
otherwise
#346: FILE: drivers/dma/ioat_dma.c:168:
+ if (--cnt == 0);
+ break;
WARNING: Trailing semicolon indicates no statements, indent implies
otherwise
#363: FILE: drivers/dma/ioat_dma.c:188:
+ if (--cnt == 0);
+ break;

-apw