Changeset View
Changeset View
Standalone View
Standalone View
sys/dev/rtsx/rtsx.c
Show First 20 Lines • Show All 3,903 Lines • ▼ Show 20 Lines | #endif /* MMCCAM */ | ||||
DEVMETHOD_END | DEVMETHOD_END | ||||
}; | }; | ||||
static devclass_t rtsx_devclass; | static devclass_t rtsx_devclass; | ||||
DEFINE_CLASS_0(rtsx, rtsx_driver, rtsx_methods, sizeof(struct rtsx_softc)); | DEFINE_CLASS_0(rtsx, rtsx_driver, rtsx_methods, sizeof(struct rtsx_softc)); | ||||
DRIVER_MODULE(rtsx, pci, rtsx_driver, rtsx_devclass, NULL, NULL); | DRIVER_MODULE(rtsx, pci, rtsx_driver, rtsx_devclass, NULL, NULL); | ||||
/* For Plug and Play */ | |||||
static struct rtsx_pciids { | |||||
imp: Does this work? I didn't think that you could specify vendor= like this. I can't seem to find… | |||||
Done Inline ActionsI test it at every boot on my laptop. I follow hlh_restart.be: I test it at every boot on my laptop.
I follow
Example 2: Using T for common vendor value
in… | |||||
Not Done Inline ActionsAh, indeed. I'd forgotten about T. imp: Ah, indeed. I'd forgotten about T.
Then this looks good to me. | |||||
uint16_t device; | |||||
const char *desc; | |||||
} rtsx_ids[] = { | |||||
{ RTSX_RTS5209, "Realtek RTS5209 PCIe SD Card Reader" }, | |||||
{ RTSX_RTS5227, "Realtek RTS5227 PCIe SD Card Reader" }, | |||||
{ RTSX_RTS5229, "Realtek RTS5229 PCIe SD Card Reader" }, | |||||
{ RTSX_RTS522A, "Realtek RTS522A PCIe SD Card Reader" }, | |||||
{ RTSX_RTS525A, "Realtek RTS525A PCIe SD Card Reader" }, | |||||
{ RTSX_RTS5249, "Realtek RTS5249 PCIe SD Card Reader" }, | |||||
{ RTSX_RTS5260, "Realtek RTS5260 PCIe SD Card Reader" }, | |||||
{ RTSX_RTL8402, "Realtek RTL8402 PCIe SD Card Reader" }, | |||||
{ RTSX_RTL8411, "Realtek RTL8411 PCIe SD Card Reader" }, | |||||
{ RTSX_RTL8411B, "Realtek RTL8411B PCIe SD Card Reader" }, | |||||
}; | |||||
mavUnsubmitted Done Inline ActionsIt would be better to reuse the list from main probe function above without duplication. I haven't looked closer into the format string of the macro, but I think it should be possible. mav: It would be better to reuse the list from main probe function above without duplication. I… | |||||
MODULE_PNP_INFO("U16:device;D:#;T:vendor=0x10ec", pci, rtsx, | |||||
rtsx_ids, nitems(rtsx_ids)); | |||||
#ifndef MMCCAM | #ifndef MMCCAM | ||||
MMC_DECLARE_BRIDGE(rtsx); | MMC_DECLARE_BRIDGE(rtsx); | ||||
#endif /* !MMCCAM */ | #endif /* !MMCCAM */ |
Does this work? I didn't think that you could specify vendor= like this. I can't seem to find the code that parses it like that, can you help me find what I'm overlooking?