Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 91028 Details for
Bug 119989
Allow configuration of udev coldplug functionality
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch to udev-start.sh for --no-scan-bus
x (text/plain), 2.76 KB, created by
Roy Marples (RETIRED)
on 2006-07-06 02:02:16 UTC
(
hide
)
Description:
Patch to udev-start.sh for --no-scan-bus
Filename:
MIME Type:
Creator:
Roy Marples (RETIRED)
Created:
2006-07-06 02:02:16 UTC
Size:
2.76 KB
patch
obsolete
>--- udev-start-090.sh 2006-05-24 12:06:39.000000000 +0100 >+++ udev-start.sh 2006-07-06 09:31:43.000000000 +0100 >@@ -1,45 +1,25 @@ > # Copyright 1999-2005 Gentoo Foundation > # Distributed under the terms of the GNU General Public License v2 > >-udev_version() { >- local version=0 >- >- if [[ -x /sbin/udev ]] ; then >- version=$(/sbin/udev -V) >- # We need it without a leading '0', else bash do the wrong thing >- version=${version##0} >- # Older udev's will print nothing >- [[ -z ${version} ]] && version=0 >- fi >- >- echo "${version}" >-} >- >- > populate_udev() { > # populate /dev with devices already found by the kernel > if [ "$(get_KV)" -gt "$(KV_to_int '2.6.14')" ] ; then > ebegin "Populating /dev with existing devices through uevents" >- udevtrigger >- eend 0 >+ local opts= >+ [[ ${RC_COLDPLUG} != "yes" ]] && opts="--no-scan-bus" >+ /sbin/udevtrigger ${opts} >+ eend $? > else > ebegin "Populating /dev with existing devices with udevstart" > /sbin/udevstart >- eend 0 >+ eend $? > fi > > # loop until everything is finished > # there's gotta be a better way... > ebegin "Letting udev process events" >- udevsettle >-# loop=0 >-# while test -d /dev/.udev/queue; do >-# sleep 0.1; >-# test "$loop" -gt 300 && break >-# loop=$(($loop + 1)) >-# done >- #einfo "loop = $loop" >- eend 0 >+ /sbin/udevsettle --timeout=60 >+ eend $? > > return 0 > } >@@ -65,7 +45,6 @@ > eend 0 > } > >- > main() { > # Setup temporary storage for /dev > ebegin "Mounting /dev for udev" >@@ -77,7 +56,8 @@ > if [[ -n ${mntcmd} ]] ; then > try mount -n ${mntcmd} > else >- if egrep -qs tmpfs /proc/filesystems ; then >+ # This is bash only, but saves on using grep >+ if [[ $(</proc/filesystems)$'\n' =~ '[[:space:]]tmpfs'$'\n' ]] ; then > mntcmd="tmpfs" > else > mntcmd="ramfs" >@@ -108,22 +88,19 @@ > seed_dev > > # Setup hotplugging (if possible) >- ebegin "Setting up proper hotplug agent" > if [[ -e /proc/sys/kernel/hotplug ]] ; then >- if [ "$(get_KV)" -gt "$(KV_to_int '2.6.14')" ] ; then >- einfo " Using netlink for hotplug events..." >+ ebegin "Setting up proper hotplug agent" >+ eindent >+ if [[ $(get_KV) -gt $(KV_to_int '2.6.14') ]] ; then >+ einfo "Using netlink for hotplug events..." > echo "" > /proc/sys/kernel/hotplug >- elif [[ $(udev_version) -ge "48" ]] ; then >- einfo " Setting /sbin/udevsend as hotplug agent ..." >- echo "/sbin/udevsend" > /proc/sys/kernel/hotplug >- elif [[ -x /sbin/hotplug ]] ; then >- einfo " Using /sbin/hotplug as hotplug agent ..." > else >- einfo " Setting /sbin/udev as hotplug agent ..." >- echo "/sbin/udev" > /proc/sys/kernel/hotplug >+ einfo "Setting /sbin/udevsend as hotplug agent ..." >+ echo "/sbin/udevsend" > /proc/sys/kernel/hotplug > fi >+ eoutdent >+ eend 0 > fi >- eend 0 > > ebegin "Starting udevd" > /sbin/udevd --daemon >@@ -144,5 +121,4 @@ > > main > >- > # vim:ts=4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 119989
:
90942
|
90943
|
91011
| 91028