lkml.org 
[lkml]   [2008]   [Dec]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] fix pktcdvd breakage from commit e105b8bfc769b0545b6f0f395179d1e43cbee822
On Sun, Nov 30, 2008 at 16:56, Kay Sievers <kay.sievers@vrfy.org> wrote:
> On Sun, Nov 30, 2008 at 15:52, Al Viro <viro@zeniv.linux.org.uk> wrote:
>> On Sun, Nov 30, 2008 at 03:28:15PM +0100, Kay Sievers wrote:
>>> > So we need to preserve the layout, with the easiest way probably being "add
>>> > one more ktype and use kobject_init_and_add() instead of that device_create()".
>>> > Sigh...
>>>
>>> What do you mean? We just need to replace the bogus "pd->pkt_dev" with
>>> MKDEV(0, 0) and we are fine.
>>
>> Userland-visible change - right now cat /sys/class/pktcdvd/pktcdvd3/dev will
>> give you dev_t of the block device in question.
>
> True, it's visible, but it's incorrect dead information which should
> be removed. Subsystem != "block is defined as S_IFCHR, and there is no
> such char device for pktcdvd. In fact the "dev" file of the pktcdvd
> class device points in many cases to a USB device, which must be
> fixed.
>
> The whole pktcdvd class is not used at all, besides for exporting a
> few files. The "dev" file at the class device is just a bug, and the
> MAJOR/MINOR uevent environment variables also. I doubt that there will
> be any visible breakage in something that isn't already totally
> broken. In short, I doubt, that anything that works today will stop
> working if we remove the bugus "dev" file.
>
> This seem like the simple and correct fix for the issue with /sys/dev/
> and the broken non-existing but exported pkcdvd char device:
> - pd->dev = device_create(class_pktcdvd, NULL, pd->pkt_dev, NULL,
> + pd->dev = device_create(class_pktcdvd, NULL, MKDEV(0, 0), NULL,

Al, this bug still exists, right? Any objections to remove the dead char dev_t?

Thanks,
Kay


\
 
 \ /
  Last update: 2008-12-05 03:59    [W:0.322 / U:0.240 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site