Re: [patch 3/5] [RFC] Add MMC Password Protection (lock/unlock) support V7: mmc_lock_unlock.diff

Anderson Briglia
2006-11-27T13:50:41Z

ext Pierre Ossman wrote:
> Anderson Briglia wrote:
>> @@ -244,5 +244,13 @@ struct _mmc_csd {
>> #define SD_BUS_WIDTH_1 0
>> #define SD_BUS_WIDTH_4 2
>>
>> +/*
>> + * MMC_LOCK_UNLOCK modes
>> + */
>> +#define MMC_LOCK_MODE_ERASE (1<<3)
>> +#define MMC_LOCK_MODE_UNLOCK (0<<2)
>> +#define MMC_LOCK_MODE_CLR_PWD (1<<1)
>> +#define MMC_LOCK_MODE_SET_PWD (1<<0)
>> +
>> #endif /* MMC_MMC_PROTOCOL_H */
>>
>
> This definition makes them look like bits, which is not how they are used.

How can I improve this? Defining using integers directly?

>
> Rgds
>