Gentoo Archives: gentoo-user

From: "Claudio Roberto França Pereira" <spideybr@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] CONFIG_USB_SUSPEND, where ?
Date: Tue, 08 Nov 2011 01:58:52
Message-Id: CAGo3WeoOzdykKrajwE9RK-n4tZydSnbb1smFCEVOEXW4Z8WzpA@mail.gmail.com
In Reply to: Re: [gentoo-user] CONFIG_USB_SUSPEND, where ? by Felix Kuperjans
1 On Sat, Oct 15, 2011 at 09:18, Felix Kuperjans <felix@××××××××××××××.com>wrote:
2
3 > Am 15.10.2011 13:57, schrieb Jonas de Buhr:
4 > > Am Sat, 15 Oct 2011 00:54:48 -0700
5 > > schrieb Canek Peláez Valdés <caneko@×××××.com>:
6 > >
7 > >> On Sat, Oct 15, 2011 at 12:49 AM, Alain Didierjean
8 > >> <alain.didierjean@××××.fr> wrote:
9 > >>> * Messages for package sys-fs/udisks-1.0.4-r1:
10 > >>>
11 > >>> * CONFIG_USB_SUSPEND: is not set when it should be.
12 > >>>
13 > >>> As the message above from emerge says, no way to update
14 > >>> sys-fs/udisks as CONFIG_USB_SUSPEND is not set. The problem is
15 > >>> where to find that option. Not in linux/.config, so where ?
16 > > i think it only shows up there if it is already set. AFAIK the
17 > > kernel options are defined in the various Kconfig files spread
18 > > throughout the source tree. in this case
19 > >
20 > > drivers/usb/core/Kconfig
21 > >
22 > > when searching for an option you can do
23 > >
24 > > find /usr/src/linux/ -name Kconfig \
25 > > -exec grep USB_SUSPEND {} /dev/null \;
26 > >
27 > > which gives you two hits:
28 > >
29 > > /usr/src/linux/drivers/usb/core/Kconfig:config USB_SUSPEND
30 > > /usr/src/linux/drivers/usb/core/Kconfig: depends on USB_SUSPEND
31 > >
32 > > and
33 > >
34 > > grep -A 20 'config USB_SUSPEND' /usr/src/linux/drivers/usb/core/Kconfig
35 > >
36 > > giving you description and help:
37 > >
38 > > config USB_SUSPEND
39 > > bool "USB runtime power management (autosuspend) and wakeup"
40 > > depends on USB && PM_RUNTIME
41 > > help
42 > > If you say Y here, you can use driver calls or the sysfs
43 > > "power/control" file to enable or disable autosuspend for
44 > > individual USB peripherals (see
45 > > Documentation/usb/power-management.txt for more details).
46 > >
47 > > Also, USB "remote wakeup" signaling is supported, whereby some
48 > > USB devices (like keyboards and network adapters) can wake up
49 > > their parent hub. That wakeup cascades up the USB tree, and
50 > > could wake the system from states like suspend-to-RAM.
51 > >
52 > > If you are unsure about this, say N here.
53 > >
54 > >
55 > >> Cool tip for the future: Go to /usr/src/linux, type "make menuconfig".
56 > >> Then type "/" (slash). Then type SUSPEND and ENTER. It will show you
57 > >> all the kernel options with SUSPEND on them.
58 > > or this, of course ;)
59 > This is my preferred way of searching the config. Note that you can't
60 > select "USB runtime and power management (autosuspend) and wakeup", if
61 > "Power management and ACPI options -> Run-time PM core functionality" is
62 > not set.
63 >
64 > I forgot that some time ago, leading to some errors while unmounting USB
65 > sticks with udisks (although most of udisks works without this option
66 > set, it just can't power down USB devices after they are unmounted).
67 > >> In particular, for USB_SUSPEND it says:
68 > >>
69 > >> Symbol: USB_SUSPEND [=y]
70 > >> Type : boolean
71 > >> Prompt: USB runtime power management (autosuspend) and wakeup
72 > >> Defined at drivers/usb/core/Kconfig:93
73 > >> Depends on: USB_SUPPORT [=y] && USB [=y] && PM_RUNTIME [=y]
74 > >> Location:
75 > >> -> Device Drivers
76 > >> -> USB support (USB_SUPPORT [=y])
77 > >> -> Support for Host-side USB (USB [=y])
78 > >>
79 > >> So there, is in Device Drivers -> USB support -> Support for
80 > >> Host-side USB.
81 > >>
82 > >> Regards.
83 >
84
85 That's extremely hardcore. Using / in menuconfig will not only give you the
86 menu where the option resides, but also state it's status (checked,
87 unchecked or module), it's dependencies and short description.