All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Yu, Mingli" <mingli.yu@windriver.com>
To: hongxu <hongxu.jia@windriver.com>,
	openembedded-core@lists.openembedded.org,
	richard.purdie@linuxfoundation.org
Subject: Re: [oe-core][PATCH 1/4] initramfs-framework/udev: umount /run/media/XXX
Date: Fri, 11 Jun 2021 15:36:49 +0800	[thread overview]
Message-ID: <b50d160f-c94d-0616-3845-d93bbc45851a@windriver.com> (raw)
In-Reply-To: <20200925070535.59518-2-hongxu.jia@windriver.com>

Ping.

Thanks,

On 9/25/20 3:05 PM, hongxu wrote:
> In initramfs-framework, udev (initramfs-module-udev) calls hook mount.sh to
> mount /run/media/XXX which is used by setup-live (initramfs-module-setup-live).
> The setup-live calls install-XXX.sh and use /run/media/XXX to do installation
> 
> The side effect is while setup-live is not used, after it switches to rootfs,
> and the mounted disk could not be released
> 
> Release the mounted disk before switch root and after kill udev
> 
> Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
> ---
>   meta/recipes-core/initrdscripts/initramfs-framework/udev | 5 +++++
>   1 file changed, 5 insertions(+)
> 
> diff --git a/meta/recipes-core/initrdscripts/initramfs-framework/udev b/meta/recipes-core/initrdscripts/initramfs-framework/udev
> index 4898b89246..8b62080c68 100644
> --- a/meta/recipes-core/initrdscripts/initramfs-framework/udev
> +++ b/meta/recipes-core/initrdscripts/initramfs-framework/udev
> @@ -8,6 +8,11 @@ udev_shutdown_hook_handler() {
>   	if [ "$status" = "pre" ] && [ "$module" = "finish" ]; then
>   		udevadm settle
>   		killall `basename $_UDEV_DAEMON` 2>/dev/null
> +
> +		# Umount other media which is mounted by udev
> +		for dir in `awk '/\/dev.* \/run\/media/{print $2}' /proc/mounts`; do
> +			umount $dir
> +		done
>   	fi
>   }
>   
> 
> 
> 
> 
> 

  reply	other threads:[~2021-06-11  7:30 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-25  7:05 Review request 0/4: multiple fixes for oe-core hongxu
2020-09-25  7:05 ` [oe-core][PATCH 1/4] initramfs-framework/udev: umount /run/media/XXX hongxu
2021-06-11  7:36   ` Yu, Mingli [this message]
2021-06-11 16:46     ` Alexander Kanavin
2020-09-25  7:05 ` [oe-core][PATCH 2/4] util-linux: fix calling uuidd failed with /run/uuidd not found hongxu
2021-06-11  7:35   ` Yu, Mingli
2020-09-25  7:05 ` [oe-core][PATCH 3/4] archive: fix racing between do_ar_patched and do_kernel_configme hongxu
2021-06-11  7:38   ` Yu, Mingli
2020-09-25  7:05 ` [oe-core][PATCH 4/4] alsa-state: run alsactl store in pkg_postinst hongxu
2021-06-11  7:39   ` Yu, Mingli

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=b50d160f-c94d-0616-3845-d93bbc45851a@windriver.com \
    --to=mingli.yu@windriver.com \
    --cc=hongxu.jia@windriver.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=richard.purdie@linuxfoundation.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.