Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] »Bus ID«
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo Chat
View previous topic :: View next topic  
Author Message
charles17
Advocate
Advocate


Joined: 02 Mar 2008
Posts: 3664

PostPosted: Mon Oct 02, 2017 7:37 am    Post subject: [SOLVED] »Bus ID« Reply with quote

On gentoo wiki there are several articles like https://wiki.gentoo.org/wiki/Gentoo_Wiki:Article_Blueprints/Hardware/Devices/Example using the term Bus ID for identifiers like 074d:0002.
I am in doubt this term is the correct or best header for that table column. In lspci manpage it is called PCI vendor and device codes.
Any idea?


Last edited by charles17 on Wed Oct 04, 2017 10:57 am; edited 1 time in total
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54028
Location: 56N 3W

PostPosted: Mon Oct 02, 2017 10:01 am    Post subject: Reply with quote

charles17,

lsusb:
Bus 006 Device 002: ID 067b:2303 Prolific Technology, Inc. PL2303 Serial Port


The correct terms are Vendor ID and Device ID.
From the example above, USB Bus 6, device 2 is a 067b:2303.

dmesg gets it right
Code:
[    3.480635] usb 6-3: New USB device found, idVendor=067b, idProduct=2303


Feel free to correct the Wiki.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7470

PostPosted: Mon Oct 02, 2017 12:35 pm    Post subject: Reply with quote

PCIID is made of vendorID and deviceID
However, as usb devices also use vendor and device ID, it might better fit to name it busID instead of pciID

Using vendorID or deviceID as header when you are speaking about the couple vendorID:deviceID would be wrong.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54028
Location: 56N 3W

PostPosted: Mon Oct 02, 2017 12:42 pm    Post subject: Reply with quote

krinn,

Bus ID is certainly not correct.
For PCI
/usr/sbin/lspci -n:

00:00.0 0600: 1022:9600
00:02.0 0604: 1022:9603
00:03.0 0604: 1022:960b
the first column is bus:function.subfunction.
The last two columns are VendorID:DeviceID.
The latter names are common to USB devices too.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7470

PostPosted: Mon Oct 02, 2017 1:24 pm    Post subject: Reply with quote

yep but the pciid is made of vendorid:deviceid not from bus, function or subfunction
see: http://pci-ids.ucw.cz/v2.2/pci.ids
it wouldn't really make sense to id an nvidia card model X because it is attach to bus Z and fail to id the same model because the card is attach to another bus.
and as usbid also use that couple (vendor:device), i don't see myself a problem naming it "busid" to refer to a generic way of saying "pciid" or "usdid".

I think the name "pciid" is for historical reason, it doesn't really even make sense, because isa bus devices were also proving the "vendorid:deviceid" couple.
Look at SLC90E66 [Victory66] (in the ids list) for example, it have a different name and deviceid, but it's just the same device on different buses.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54028
Location: 56N 3W

PostPosted: Mon Oct 02, 2017 1:50 pm    Post subject: Reply with quote

krinn,

The heading VendorID/DeviceID works for both PCI and USB buses.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Tue Oct 03, 2017 10:47 pm    Post subject: Reply with quote

krinn wrote:
the pciid is made of vendorid:deviceid not from bus, function or subfunction
which means it's a device identifier, not a bus identifier. device id := vendor_id : vendor_dev
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7470

PostPosted: Wed Oct 04, 2017 10:30 am    Post subject: Reply with quote

steveL wrote:
krinn wrote:
the pciid is made of vendorid:deviceid not from bus, function or subfunction
which means it's a device identifier, not a bus identifier. device id := vendor_id : vendor_dev

Exactly, it's a device identifier, but if you name it deviceID people will mistake such name with the x:deviceID part of the couple.

If we accept (and it is already for years) that the couple is name PCIID or USBID, i don't see myself a problem to generalize that into BUSID.

What is sure, is that if you change the wiki header to deviceID or vendorID, you will fail to point it's the "couple" and not a part of it.
It might also be good to simply name the header "device identifier", but deviceID would not.
Back to top
View user's profile Send private message
charles17
Advocate
Advocate


Joined: 02 Mar 2008
Posts: 3664

PostPosted: Wed Oct 04, 2017 10:56 am    Post subject: Reply with quote

NeddySeagoon wrote:
charles17,

lsusb:
Bus 006 Device 002: ID 067b:2303 Prolific Technology, Inc. PL2303 Serial Port


The correct terms are Vendor ID and Device ID.

Yep. that's what I think should be the preferred notation, as on https://wiki.gentoo.org/wiki/AC1200_Wireless_Adapters#PCI
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Sun Oct 08, 2017 10:35 am    Post subject: Reply with quote

steveL wrote:
krinn wrote:
the pciid is made of vendorid:deviceid not from bus, function or subfunction
which means it's a device identifier, not a bus identifier. device id := vendor_id : vendor_dev
krinn wrote:
Exactly, it's a device identifier, but if you name it deviceID people will mistake such name with the x:deviceID part of the couple.
But that's already inaccurate: that "part of the couple" is not a device_id: it's a product_id (or "vendor_dev".)
It only forms a device_id when paired with the precise, relevant vendor ID; otherwise it means nothing.
Quote:
If we accept (and it is already for years) that the couple is name PCIID or USBID, i don't see myself a problem to generalize that into BUSID.
It's allowing more inaccuracy to creep in; a PCI_ID could be either a PCI_dev or a bus_ID (and personally I'd assume the latter, when it matters.)
Quote:
What is sure, is that if you change the wiki header to deviceID or vendorID, you will fail to point it's the "couple" and not a part of it.
It might also be good to simply name the header "device identifier", but deviceID would not.
Device_ID is accurate IMO: it just needs to be indicated that it's made of two fields. If you prefer:
device id := vendor_id : product_id
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7470

PostPosted: Sun Oct 08, 2017 11:19 am    Post subject: Reply with quote

steveL wrote:
But that's already inaccurate: that "part of the couple" is not a device_id: it's a product_id (or "vendor_dev".)

See
http://pci-ids.ucw.cz/v2.2/pci.ids wrote:
# Vendors, devices and subsystems. Please keep sorted.
# Syntax:
# vendor vendor_name
# device device_name <-- single tab
# subvendor subdevice subsystem_name <-- two tabs

or
http://elixir.free-electrons.com/linux/latest/source/include/uapi/linux/pci_regs.h wrote:

#define PCI_VENDOR_ID 0x00 /* 16 bits */
#define PCI_DEVICE_ID 0x02 /* 16 bits */


I think they have change the terms for USBID, and do use vendor:product terms, but PCIID was made earlier
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Thu Oct 12, 2017 6:07 am    Post subject: Reply with quote

krinn, I don't really care what someone else calls it, ofc.

I just think that creeping inaccuracy in nomenclature, is a more serious long-term problem than is generally realised.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo Chat All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum