Skip to contentSkip to conversation

usb: ehci-vf: take the register bases from the device tree

PATCH Mehmet Fide 2 participants 3 messages Oct 18 – Oct 19 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

Hi Marek,

Quoted 3 lines · Marek Vasut

Why did the portnr data type change here ?

Can portnr be negative ?

ofnode_get_alias_seq() writes an int, the same contract as dev_read_alias_seq(), so the field takes its type. The value is the usbphy alias number, 0 or 1, never negative: when the lookup fails the function returns the error before the field is read. I will say so in the commit message of v7.

Thanks,
Mehmet

#2 lore raw
Quoted 5 lines · Mehmet Fide

Hi Marek,

Quoted 2 lines · Marek Vasut

Why did the portnr data type change here ?

Quoted 7 lines
Quoted 1 line

Can portnr be negative ?

ofnode_get_alias_seq() writes an int, the same contract as dev_read_alias_seq(), so the field takes its type. The value is the usbphy alias number, 0 or 1, never negative: when the lookup fails the function returns the error before the field is read. I will say so in the commit message of v7.

It seems portnr should be unsigned int in struct ehci_vf_priv_data {} ?

#3 lore raw

Hi Marek,

Quoted 1 line · Marek Vasut

It seems portnr should be unsigned int in struct ehci_vf_priv_data {} ?

Yes, v7 keeps it a u32.

Thanks,
Mehmet