Get USBHUB PDO to get USB serial number

Hi All,
I am trying to get the serial number of USB mass storage devices. Following recommendations of previous topics in this list, I found that I need to talk to the USBHUB PDO to get this information. Is there any way in kernel mode to get this starting from the USBSTOR PDO?
Thanks in advance,
Yohamnes

No, there is no way to get the parents pdo from your child stack

d

debt from my phone


From: xxxxx@segurmatica.cu
Sent: 11/28/2011 7:24 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] Get USBHUB PDO to get USB serial number

Hi All,
I am trying to get the serial number of USB mass storage devices. Following recommendations of previous topics in this list, I found that I need to talk to the USBHUB PDO to get this information. Is there any way in kernel mode to get this starting from the USBSTOR PDO?
Thanks in advance,
Yohamnes


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

See if IOCTL_STORAGE_GET_MEDIA_SERIAL_NUMBER works for you

Thanks a lot, Doron. That was I was suspecting:-(
Just another simple questions:
Getting USB serial number from minifilter with IOCTL_STORAGE_QUERY_PROPERTY to the disk pdo does not seem to work (I know there are USB disks without serial numbers but I am checking against USBView) . IOCTL_STORAGE_GET_MEDIA_SERIAL_NUMBER returns “not supported”. Using SCSI pass through to the disk pdo would give me better results?
If this last option does not work neither, then I could affirm that there is not way in kernel mode to obtain the serial number of USB storage device from minifilter??
Best regards,
Yohamnes

So there are two serial numbers here, right? The usb device itself
should have a serial number as per the usb spec, and then the storage
device implemented by the usb device should also have a serial number
as per the relevant storage spec. These need not be the same serial
number, in fact they most likely aren’t as the specs involved have
different requirements for their respective serial numbers.

Mark Roddy

On Mon, Nov 28, 2011 at 11:02 AM, wrote:
> See if IOCTL_STORAGE_GET_MEDIA_SERIAL_NUMBER works for you
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer
>