Skip to contentSkip to conversation

struct char_device

PATCH [email protected] 2 participants 2 messages May 22, 2001

lore
Share & tools
lore
#0 lore raw
Quoted 1 line · Martin Dalecki

I fully agree with you.

Good.

Unfortunately I do not fully agree with you.

Quoted 3 lines

Most of the places where there kernel is passing kdev_t would be entierly satisfied with only the knowlendge of the minor number.

My kdev_t is a pointer to a structure with device data and device operations. Among the operations a routine that produces a name. Among the data, in the case of a block device, the size, and the sectorsize, ..

A minor gives no name, and no data.

Linus' minor is 20-bit if I recall correctly. My minor is 32-bit. Neither of the two can be used to index arrays.

Andries

#1 lore raw
Quoted 18 lines · [email protected] wrote:
Quoted 1 line · Martin Dalecki

I fully agree with you.

Good.

Unfortunately I do not fully agree with you.

Quoted 3 lines

Most of the places where there kernel is passing kdev_t would be entierly satisfied with only the knowlendge of the minor number.

My kdev_t is a pointer to a structure with device data and device operations. Among the operations a routine that produces a name. Among the data, in the case of a block device, the size, and the sectorsize, ..

Quoted 5 lines

A minor gives no name, and no data.

Linus' minor is 20-bit if I recall correctly. My minor is 32-bit. Neither of the two can be used to index arrays.

Erm... I wasn't talking about the DESIRED state of affairs! I was talking about the CURRENT state of affairs. OK? The fact still remains that most of the places which a have pointed out just need the minor nibble of whatever bits you pass to them.

Apparently nobody on this list here blabbering about a new improved minor/major space didn't actually take the time and looked into all those places where the kernel is CURRENTLY replying in minor/major array enumeration. They are TON's of them. The most ugly are RAID drivers
an all those MD LVW and whatever stuff as well as abused minor number spaces as replacements of differnt majors.

At least you have admitted that you where the one responsible for the design of this MESS.