Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 25 Sep 2018 16:29:04 +0300
From:      Yuri Pankov <yuripv@yuripv.net>
To:        Warner Losh <imp@bsdimp.com>
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: allow specifying literal values in MODULE_PNP_INFO(9)
Message-ID:  <880c1557-6eba-b624-3a0f-73f67a38edc7@yuripv.net>
In-Reply-To: <CANCZdfqg1dawUuC6N%2BoB3a2-syEScik_ZMyk5%2BOK8pM02yzoQA@mail.gmail.com>
References:  <2926f43a-4709-3335-07a4-03248e13675a@yuripv.net> <CANCZdfqg1dawUuC6N%2BoB3a2-syEScik_ZMyk5%2BOK8pM02yzoQA@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Warner Losh wrote:
> On Tue, Sep 25, 2018 at 7:12 AM Yuri Pankov <yuripv@yuripv.net> wrote:
> 
>> Hi,
>>
>> Looking at adding the MODULE_PNP_INFO() entry to iwm(4), I came up with
>> the patch in https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=231625
>> adding redundant and useless vendor field to iwm_devices.  While it
>> works, it's unfortunate, and I have started looking into possible
>> solutions and the result is a small patch for kldxref(8) allowing
>> specifying literal values in descriptor_string like the following:
>>
>> MODULE_PNP_INFO("U16=8086:vendor;U16:device;P:#", pci, iwm_pci_driver,
>>       iwm_devices, sizeof(iwm_devices[0]), nitems(iwm_devices));
>>
>> ...so that we always have vendor 0x8086 and only consume the device field.
>>
>> If it makes at least some sense, I'll put it for review.
>>
> 
> So what's wrong with using the T type that's already implemented?
> T:device=0x8086?

Nothing other than my inability to read and understand the 
documentation.  I'm actually happy that it already exists.  Thanks and 
sorry for the noise.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?880c1557-6eba-b624-3a0f-73f67a38edc7>