From: Harald Hoyer <harald-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
To: Michal Soltys <soltys-R61QfzASbfY@public.gmane.org>
Cc: initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH] init: fix for setting udev logging priority
Date: Tue, 02 Aug 2011 15:00:19 +0200 [thread overview]
Message-ID: <4E37F4E3.90301@redhat.com> (raw)
In-Reply-To: <1312289216-5958-1-git-send-email-soltys-R61QfzASbfY@public.gmane.org>
[-- Attachment #1: Type: text/plain, Size: 1607 bytes --]
On 02.08.2011 14:46, Michal Soltys wrote:
> Previously udevproperty() function was called, which would lead to
> setting not intended properties instead of actually adjusting logging
> priority, e.g.:
>
> udevadm control --property=--log-priority=info
>
> Now, udevadm is called directly from the init script.
>
> Signed-off-by: Michal Soltys <soltys-R61QfzASbfY@public.gmane.org>
> ---
> modules.d/99base/init | 10 ++++------
> 1 files changed, 4 insertions(+), 6 deletions(-)
>
> diff --git a/modules.d/99base/init b/modules.d/99base/init
> index ae834be..34a8aef 100755
> --- a/modules.d/99base/init
> +++ b/modules.d/99base/init
> @@ -189,16 +189,14 @@ source_hook pre-udev
> # start up udev and trigger cold plugs
> udevd --daemon --resolve-names=never
>
> -UDEV_LOG_PRIO_ARG=--log-priority
> -UDEV_QUEUE_EMPTY="udevadm settle --timeout=0"
> -
> if [ $UDEVVERSION -lt 140 ]; then
> - UDEV_LOG_PRIO_ARG=--log_priority
> UDEV_QUEUE_EMPTY="udevadm settle --timeout=1"
> +else
> + UDEV_QUEUE_EMPTY="udevadm settle --timeout=0"
> fi
>
> -getargbool 0 rd.udev.info -y rdudevinfo && udevproperty "$UDEV_LOG_PRIO_ARG=info"
> -getargbool 0 rd.udev.debug -y rdudevdebug && udevproperty "$UDEV_LOG_PRIO_ARG=debug"
> +getargbool 0 rd.udev.info -y rdudevinfo && udevadm control --log-priority=info
> +getargbool 0 rd.udev.debug -y rdudevdebug && udevadm control --log-priority=debug
> udevproperty "hookdir=$hookdir"
>
> getarg 'rd.break=pre-trigger' 'rdbreak=pre-trigger' && emergency_shell -n pre-trigger "Break before pre-trigger"
I think the attached patch solves the problem:
[-- Attachment #2: dracut-udevadm-control.patch --]
[-- Type: text/plain, Size: 1120 bytes --]
commit e36ee58d0e269e6a403f184177d4f14f05b1d3d0
Author: Harald Hoyer <harald-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
Date: Tue Aug 2 14:57:49 2011 +0200
99base/init: use udevadm control to set the logging priority
due to a bad revert commit, "udevadm control" was converted to
"udevproperty", which is the wrong command to set the logging priority.
diff --git a/modules.d/99base/init b/modules.d/99base/init
index ae834be..b991196 100755
--- a/modules.d/99base/init
+++ b/modules.d/99base/init
@@ -197,8 +197,8 @@ if [ $UDEVVERSION -lt 140 ]; then
UDEV_QUEUE_EMPTY="udevadm settle --timeout=1"
fi
-getargbool 0 rd.udev.info -y rdudevinfo && udevproperty "$UDEV_LOG_PRIO_ARG=info"
-getargbool 0 rd.udev.debug -y rdudevdebug && udevproperty "$UDEV_LOG_PRIO_ARG=debug"
+getargbool 0 rd.udev.info -y rdudevinfo && udevadm control "$UDEV_LOG_PRIO_ARG=info"
+getargbool 0 rd.udev.debug -y rdudevdebug && udevadm control "$UDEV_LOG_PRIO_ARG=debug"
udevproperty "hookdir=$hookdir"
getarg 'rd.break=pre-trigger' 'rdbreak=pre-trigger' && emergency_shell -n pre-trigger "Break before pre-trigger"
prev parent reply other threads:[~2011-08-02 13:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-02 12:46 [PATCH] init: fix for setting udev logging priority Michal Soltys
[not found] ` <1312289216-5958-1-git-send-email-soltys-R61QfzASbfY@public.gmane.org>
2011-08-02 13:00 ` Harald Hoyer [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4E37F4E3.90301@redhat.com \
--to=harald-h+wxahxf7alqt0dzr+alfa@public.gmane.org \
--cc=initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=soltys-R61QfzASbfY@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox