LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 12-01-2003, 11:13 AM   #1
WhiteTornado
Member
 
Registered: May 2003
Location: MONTREAL
Distribution: FEDORA
Posts: 63

Rep: Reputation: 15
Smile Question on a term


Hi,

As I am now learning on Linux, I ran into this term which I am trying to figure out and am having a lot of trouble:

Can someone help me with defining what the term OFFSET refers to in the below text:

tks and cheers!

All devices controlled by the same device driver have a common major device number. The minor device numbers are used to distinguish between different devices and their controllers. Linux maps the device special file passed in system calls (say to mount a file system on a block device) to the device's device driver using the major device number and a number of system tables, for example the character device table, chrdevs. The major number is actually the OFFSET into the kernel's device driver table, which tells the kernel what kind of device it is (whether it is a hard disk or a serial terminal). The minor number tells the kernel special characteristics of the device to be accessed. For example, the second hard disk has a different minor number than the first. The COM1 port has a different minor number than the COM2 port, each partition on the primary IDE disk has a different minor device number, and so forth. So, for example, /dev/hda2, the second partition of the primary IDE disk has a major number of 3 and a minor number of 2.
 
Old 12-01-2003, 11:19 AM   #2
szaroubi
Member
 
Registered: Oct 2003
Location: Montreal
Distribution: All/Any
Posts: 59

Rep: Reputation: 15
Extreemly Basic Example:

Kernel Device Driver Table

0 : aDevice
1 : deviceFoo
2 : fooDeviceBar
.
.
.


The offset is the index of the device .. The offset from the start of the table.
The offset/index of the array .
 
Old 12-01-2003, 12:14 PM   #3
WhiteTornado
Member
 
Registered: May 2003
Location: MONTREAL
Distribution: FEDORA
Posts: 63

Original Poster
Rep: Reputation: 15
Thanks szaroubi,

I get it, just the index, so here, it is the index of the device drivers, boy, I was unable to find that anywhere on the net... !

cheers!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Power term Katsukhan Linux - Newbie 0 07-09-2004 04:28 PM
looking for nice term for x pe2338 Debian 14 09-23-2003 01:56 PM
x term Gordon Linux - General 1 03-26-2003 11:44 PM
term in Vi NSKL Linux - Software 19 12-04-2002 02:29 AM
term colors ?? xlord Linux - General 3 10-12-2002 01:41 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:01 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration