On Saturday 28 July 2007 00:24:42 Tomas Winkler wrote: > On 7/27/07, Michael Buesch <mb@xxxxxxxxx> wrote: > > On Friday 27 July 2007 11:26:33 Zhu Yi wrote: > > > if (!(r & 1)) { > > > IWL_ERROR("Time out reading EEPROM[%d]", addr); > > > - return -ETIMEDOUT; > > > + rc = -ETIMEDOUT; > > > + goto done; > > > } > > > > > > e[addr / 2] = le16_to_cpu(r >> 16); > > > > Seems like you really want cpu_to_le16() here, as "r" should better > > be CPU-endian when shifting it by >>. > > > > Though, I don't see enough code context here to judge if the > > endianess conversion is correct at all or not. > > > This line is empirically correct. No, you need cpu_to_le16 here, instead of le16_to_cpu. I know that these generate the same code, but it makes a difference for sparse. -- Greetings Michael. - To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html