[prev in list] [next in list] [prev in thread] [next in thread]
List: busybox
Subject: Re: about buysbox mdev
From: Denys Vlasenko <vda.linux () googlemail ! com>
Date: 2010-08-16 12:33:50
Message-ID: AANLkTimvBJuY+Fd3QjjRyx+k5KqRSX4oPfTYQr4vmZ64 () mail ! gmail ! com
[Download RAW message or body]
On Sun, Aug 15, 2010 at 11:29 AM, 何家胜 <asmcos@akaedu.org> wrote:
> I use busybox 1.17.0. When I insert a device.
> mdev can create a device file at /dev/.
>
> When I remove the device ,mdev cann't delete the device file.
>
> I use busybox 1.13.0. mdev can work.
>
> in busybox 1.17.0 mdev.c
>
> static void make_device(char *path, int delete)
> {
> line ...
> 382:
> if (delete && major >= 0) { //major = -1, so We cann't delete device
>
> ....//
> }
> }
>
> The busybox from 1.13 to 1.16 mdev.c
> static void make_device(char *path, int delete)
> {
>
> if (delete) //no (major >=0)
> {
> }
> }
>
>
> The busybox 1.17.0
>
> static void make_device(char *path, int delete)
> {
>
> // line 382
>
> why need the "(major >= 0)" ?
>
>
> }
The idea was to make "!" alias (which means "don't create/delete this node")
to really _not_ delete the node. But accidentally it prevented node deletion
in all cases! :(
Thanks for finding it. Here's the patch:
http://busybox.net/downloads/fixes-1.17.1/busybox-1.17.1-mdev.patch
--
vda
_______________________________________________
busybox mailing list
busybox@busybox.net
http://lists.busybox.net/mailman/listinfo/busybox
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic