Re: MMC: logical-bitwise and confusion in tifm_sd_transfer_data()?

From: Alex Dubov
Date: Tue Mar 11 2008 - 03:41:18 EST



--- Pierre Ossman <drzeus-mmc@xxxxxxxxx> wrote:

> On Sun, 09 Mar 2008 21:31:08 +0100
> Roel Kluin <12o3l@xxxxxxxxxx> wrote:
>
> > from drivers/mmc/host/tifm_sd.c:183:
> >
> > if ((r_data->flags & MMC_DATA_WRITE)
> > && DATA_CARRY)
> >
> > shouldn't this be bit-wise &?
>
> First off, I'm not the maintainer of that driver, Alex Dubov is.
>
> Second, the code seems broken, but not in the way you suggest. It should probably have been:
>
> if ((r_data->flags & MMC_DATA_WRITE)
> && (host->cmd_flags & DATA_CARRY))
>

Yes, this is the intended meaning. Can you fix it yourself or should I send a separate patch?



____________________________________________________________________________________
Looking for last minute shopping deals?
Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping
--
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/