Sponsored Content
Operating Systems Solaris some questions on the minor number of device Post 302556524 by ForgetChen on Monday 19th of September 2011 03:26:36 AM
Old 09-19-2011
some questions on the minor number of device

hi, dear all

Now I have a problem on the minor number of device.

I have many sd disks. The sd driver will create many minor numbers for these disks when attached.
But the sd driver may be not remove thest minor number when detached.

The minor number will become very big If I attach and detach these disks again and again.
And at last thest disks will be attached failed because the reason "WARNING: sd32845:a minor 0x40268 too big for 32-bit applications"

So my question is:
1)Why the sd driver create the minor number but not to remove it?
Need I remove these minor numbers by myself?
If I need , how?
2)How can I do if the disks attached failed because the minor number is too big?

Thanks!
 

9 More Discussions You Might Find Interesting

1. Programming

How to check number of first slot on the MO or TAPE device?

Hi, I need to discover is MO or Tape device counting slots begining on 0 or 1. THS (0 Replies)
Discussion started by: HrnjicaMujo
0 Replies

2. Programming

Device Major/Minor numbers

To further my fledgling knowledge of C, I am re-writing some of the Unix command set. My current command is an ls-style command. All works well, except for device files. How do I get the major/minor numbers for the dev files? I see from the stat struct there are st_rdev and st_dev members. Do... (1 Reply)
Discussion started by: zazzybob
1 Replies

3. Solaris

major & minor number

Hi Can anyone tell me what is major number and minor number in the mknod command. Also what these numbers mean. I have gone through the man pages but still I couldn't understand. Regards (3 Replies)
Discussion started by: RajaRC
3 Replies

4. Solaris

questions on how to install Solaris 10 via DVD/RW external device

Whoa...glad to see this forum si up and running, as a few weeks ago I tried to check in and found it directing me somewhere else and felt maybe this board was being hijacked or someone was closing down this forum. Here is a problem I am having. I got a SunFire V100 and disc with Solaris 10 on... (8 Replies)
Discussion started by: bluridge
8 Replies

5. Linux

Device serial number

Hey! I'm trying to figure out a sollution for a problem I have at my company with an Iomega MiniMax 500 GB USB disk. If i run cat /proc/bus/usb/devices I get this information: T: Bus=01 Lev=02 Prnt=04 Port=00 Cnt=01 Dev#= 5 Spd=480 MxCh= 0 D: Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00... (2 Replies)
Discussion started by: noratx
2 Replies

6. Solaris

V-5-1-663 Duplicate virtual device number

hi folks here is my case Storage XP24K Business copy setup OS Solaris 10 Verital 4.1 Business copy is running between a production server and backup server using xp24k when the disk groups are imported back on backup server after BC from the prduction server following error is reported... (0 Replies)
Discussion started by: ajays
0 Replies

7. Solaris

Help with Major and minor number

Hi Does anyone know what the major and minor numbers are in Solaris? (2 Replies)
Discussion started by: wisdom
2 Replies

8. Solaris

Major and Minor number of Virtual File System

Hi friends, Please let me know if there is any way to find out Major and Minor numbers of virtual file system like below: /devices 0K 0K 0K 0% /devices ctfs 0K 0K 0K 0% /system/contract proc 0K 0K ... (8 Replies)
Discussion started by: nitj
8 Replies

9. UNIX for Advanced & Expert Users

device number registration

I would THANK if you answer my doubts in DETAILS please. Here's a sample code to create a device: if(scull_major) { dev=MKDEV(scull_major, scull_minor); result=register_chrdev_region(dev, scull_nr_devs, "scull"); } else{ result=alloc_chrdev_region(&dev, scull_minor,... (2 Replies)
Discussion started by: dr_mabuse
2 Replies
MAKEDEV(3)						   BSD Library Functions Manual 						MAKEDEV(3)

NAME
makedev, major, minor -- device number conversion SYNOPSIS
#include <sys/types.h> dev_t makedev(int major, int minor); int major(dev_t dev); int minor(dev_t dev); DESCRIPTION
The makedev() macro allows a unique device number to be generated based on its major and minor number. The major() and minor() macros can be used to obtain the original numbers from the device number dev. In previous implementations of FreeBSD all block and character devices were uniquely identified by a pair of major and minor numbers. The major number referred to a certain device class (e.g. disks, TTYs) while the minor number identified an instance within the device class. Later versions of FreeBSD automatically generate a unique device number for each character device visible in /dev/. These numbers are not divided in device classes. On FreeBSD these macros are only used by utilities that need to exchange numbers with other operating systems that may use different encod- ings for dev_t, but also applications that present these numbers to the user in a more conventional way. RETURN VALUES
The major() macro returns a device major number that has a value between 0 and 255. The minor() macro returns a device minor number whose value can span the complete range of an int. SEE ALSO
mknod(2), devname(3), devfs(5) BSD
September 28, 2008 BSD
All times are GMT -4. The time now is 07:01 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy