Re: [PATCH 2.6.35-rc1] net-next: vmxnet3 fixes [2/5] Interruptcontrol bitmap

From: David Miller
Date: Wed Jul 14 2010 - 17:04:24 EST


From: Shreyas Bhatewara <sbhatewara@xxxxxxxxxx>
Date: Tue, 13 Jul 2010 17:48:04 -0700 (PDT)

> - __le32 reserved[3];
> + __le32 intrCtrl;
> + __le32 reserved[2];
> };
>
...
> + adapter->shared->devRead.intrConf.intrCtrl &= ~VMXNET3_IC_DISABLE_ALL;
...
> + adapter->shared->devRead.intrConf.intrCtrl |= VMXNET3_IC_DISABLE_ALL;
...
> + devRead->intrConf.intrCtrl |= VMXNET3_IC_DISABLE_ALL;

You need to use cpu_to_le32() and similar when accessing this value.

If you run "sparse" with endianness checking enabled you'll see
warnings showing alerting you to this issue...
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/