RE: [PATCH RESEND 1/2] HID: hid-sensor-hub: Remove setting hdev->claimed before calling hid_hw_start()

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

 



I felt subject line was too long. Minor change in subject line. Tested and added my ack for both of these patches.

Thanks,
Srinivas

-----Original Message-----
From: Jiri Kosina [mailto:jkosina@xxxxxxx] 
Sent: Wednesday, September 19, 2012 4:46 AM
To: Axel Lin
Cc: Jonathan Cameron; Pandruvada, Srinivas; linux-input@xxxxxxxxxxxxxxx
Subject: Re: [PATCH RESEND 1/2] HID: hid-sensor-hub: Remove setting hdev->claimed before calling hid_hw_start()

On Tue, 18 Sep 2012, Axel Lin wrote:

> Current implementation of hid_hw_start() allows connect_mask to be 0.
> Setting hdev->claimed = HID_CLAIMED_INPUT before calling 
> hid_hw_start() is not necessary. Remove it.
> 
> Signed-off-by: Axel Lin <axel.lin@xxxxxxxxx>

Signed-off-by: Jiri Kosina <jkosina@xxxxxxx>

Jonathan, please take it on top of the other changes.

Thanks.

> ---
>  drivers/hid/hid-sensor-hub.c |    2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/drivers/hid/hid-sensor-hub.c 
> b/drivers/hid/hid-sensor-hub.c index 4ac759c..1faacf2 100644
> --- a/drivers/hid/hid-sensor-hub.c
> +++ b/drivers/hid/hid-sensor-hub.c
> @@ -539,7 +539,6 @@ static int sensor_hub_probe(struct hid_device *hdev,
>  	}
>  	INIT_LIST_HEAD(&hdev->inputs);
>  
> -	hdev->claimed = HID_CLAIMED_INPUT;
>  	ret = hid_hw_start(hdev, 0);
>  	if (ret) {
>  		hid_err(hdev, "hw start failed\n"); @@ -627,7 +626,6 @@ static void 
> sensor_hub_remove(struct hid_device *hdev)
>  	int i;
>  
>  	hid_dbg(hdev, " hardware removed\n");
> -	hdev->claimed &= ~HID_CLAIMED_INPUT;
>  	hid_hw_stop(hdev);
>  	hid_hw_close(hdev);
>  	spin_lock_irqsave(&data->lock, flags);
> --
> 1.7.9.5
> 
> 
> 

--
Jiri Kosina
SUSE Labs
--
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