Re: [PATCH 1/3] HID: picolcd: fix misuse of logical operation in place of bitop

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thanks for spotting,

Acked-by: Bruno PrÃmont <bonbons@xxxxxxxxxxxxxxxxx>

On Mon, 27 December 2010 David Sterba <dsterba@xxxxxxx> wrote:
> CC: Bruno PrÃmont <bonbons@xxxxxxxxxxxxxxxxx>
> CC: Jiri Kosina <jkosina@xxxxxxx>
> Signed-off-by: David Sterba <dsterba@xxxxxxx>
> ---
>  drivers/hid/hid-picolcd.c |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/hid/hid-picolcd.c b/drivers/hid/hid-picolcd.c
> index bc2e077..0aff3cd 100644
> --- a/drivers/hid/hid-picolcd.c
> +++ b/drivers/hid/hid-picolcd.c
> @@ -1544,7 +1544,7 @@ static ssize_t picolcd_debug_eeprom_read(struct file *f, char __user *u,
>  
>  	/* prepare buffer with info about what we want to read (addr & len) */
>  	raw_data[0] = *off & 0xff;
> -	raw_data[1] = (*off >> 8) && 0xff;
> +	raw_data[1] = (*off >> 8) & 0xff;
>  	raw_data[2] = s < 20 ? s : 20;
>  	if (*off + raw_data[2] > 0xff)
>  		raw_data[2] = 0x100 - *off;
> @@ -1583,7 +1583,7 @@ static ssize_t picolcd_debug_eeprom_write(struct file *f, const char __user *u,
>  
>  	memset(raw_data, 0, sizeof(raw_data));
>  	raw_data[0] = *off & 0xff;
> -	raw_data[1] = (*off >> 8) && 0xff;
> +	raw_data[1] = (*off >> 8) & 0xff;
>  	raw_data[2] = s < 20 ? s : 20;
>  	if (*off + raw_data[2] > 0xff)
>  		raw_data[2] = 0x100 - *off;
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux