lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 5 May 2010 21:17:42 +0200
From:	Bruno Prémont <bonbons@...ux-vserver.org>
To:	Jiri Kosina <jkosina@...e.cz>
Cc:	Oliver Neukum <oneukum@...e.de>,
	linux-pm@...ts.linux-foundation.org,
	list <linux-usb@...r.kernel.org>,
	Kernel development list <linux-kernel@...r.kernel.org>,
	Alan Stern <stern@...land.harvard.edu>
Subject: Re: [linux-pm] s2ram slow (radeon) / failing (usb)

On Wed, 05 May 2010 Jiri Kosina <jkosina@...e.cz> wrote:

> On Tue, 4 May 2010, Bruno Prémont wrote:
> 
> > > Bruno, could you, for testing purposes, check, whether the patch below 
> > > changes the behavior you are seeing (and also check what the actual return 
> > > value from device_add() was, see the added printk()).
> > 
> > Well, it's said to return 0:
> > 
> > [  286.872739] generic-usb 0003:058F:9462.0003: input: USB HID v1.10 Keyboard [Multimedia USB Keyboard Multimedia USB Keyboard] on usb-0000:00:13.0-2.1/input0
> > [  286.890136] HID: device_add() returned 0
> > 
> > [  286.919698] generic-usb: probe of 0003:058F:9462.0004 failed with error -22
> > [  286.929363] HID: device_add() returned 0
> > 
> > or with debug=1 for HID:
> > [  559.982958] /usr/src/linux-2.6-git/drivers/hid/usbhid/hid-core.c: HID probe called for ifnum 1
> > [  560.011698] /usr/src/linux-2.6-git/drivers/hid/hid-core.c: usage index exceeded
> > [  560.011704] /usr/src/linux-2.6-git/drivers/hid/hid-core.c: hid_add_usage failed
> > [  560.011710] /usr/src/linux-2.6-git/drivers/hid/hid-core.c: item 0 2 2 2 parsing failed
> > [  560.011732] /usr/src/linux-2.6-git/drivers/hid/usbhid/hid-core.c: parsing report descriptor failed
> > [  560.011747] generic-usb: probe of 0003:058F:9462.0006 failed with error -22
> > [  560.021718] HID: device_add() returned 0
> 
> Could you please verify with this patch? Thanks.

No difference, the second interface remains registered with HID bus
and I don't spot any difference in kernel log.

Going to have a look at what probe exactly it's that returns -EINVAL
and then attempt to unroll it up to device_add() ...
Hopefully I will find the function that does not hand back the failure.

Thanks,
Bruno

>  drivers/hid/hid-core.c |    4 +++-
>  1 files changed, 3 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c
> index 2e2aa75..8df19d3 100644
> --- a/drivers/hid/hid-core.c
> +++ b/drivers/hid/hid-core.c
> @@ -1486,8 +1486,10 @@ static int hid_device_probe(struct device *dev)
>  			if (!ret)
>  				ret = hid_hw_start(hdev, HID_CONNECT_DEFAULT);
>  		}
> -		if (ret)
> +		if (ret) {
>  			hdev->driver = NULL;
> +			ret = -ENODEV;
> +		}
>  	}
>  	return ret;
>  }
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ