Re: [RFC 2] userconf(4): 2nd proposal

2023-11-05 Thread Staffan Thomén
One thing I'd like to point out is that I often find I don't have the right keyboard layout or am restricted in some way in from typing in the bootloader (glitchy serial connection or really fast repeating keyboard or something), so keeping the syntax brief and with as few non- alphabetical

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-05 Thread tlaronde
FWIW, various things I have modified can be seen here: https://github.com/tlaronde/netbsd-src/tree/tsjl The userconf version present at the moment on the published branch, was my first attempt (patterns introduced by slashes---working but not solving the problem about drmkms). There are other

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-05 Thread tlaronde
On Sun, Nov 05, 2023 at 11:17:02AM +, RVP wrote: > > Oh, I like the idea (I've always wanted a mechanism to list drivers > etc. using patterns); it's just the syntax that sticks in the craw. > Too many meta-chars. there. > > OTOH, `cmd -p xyz* *abc' doesn't need much thought. And, aliases >

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-05 Thread tlaronde
On Sun, Nov 05, 2023 at 01:53:31PM +0200, Staffan Thomén wrote: > One thing I'd like to point out is that I often find I don't have the > right keyboard layout or am restricted in some way in from typing in the > bootloader (glitchy serial connection or really fast repeating keyboard > or

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-05 Thread RVP
On Sat, 4 Nov 2023, tlaro...@kergis.com wrote: You can also add, let's say, a `-g' group flag: uc> list -g # list all "groups" uc> list -g drmkms # list devices in group drmkms uc> disable -g drmkms# disable group drmkms Yep, but know you see what

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-04 Thread tlaronde
On Sat, Nov 04, 2023 at 11:59:00AM +0100, Martin Husemann wrote: > On Sat, Nov 04, 2023 at 11:25:01AM +0100, tlaro...@kergis.com wrote: > > I think that my second proposal is the simplest, allowing not breaking > > existing and introducing extensions without much typing. > > This whole thing

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-04 Thread Martin Husemann
On Sat, Nov 04, 2023 at 11:25:01AM +0100, tlaro...@kergis.com wrote: > I think that my second proposal is the simplest, allowing not breaking > existing and introducing extensions without much typing. This whole thing still makes no sense to me. You can do what you want with userconf already and

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-04 Thread tlaronde
On Sat, Nov 04, 2023 at 09:30:53AM +, RVP wrote: > On Sat, 4 Nov 2023, tlaro...@kergis.com wrote: > > > > > No...: this is a break of existing. Trailing `*' selects STARred devices > > > > (I'm not the inventor of this). So `*' can not be used as a joker ;-) > > > > > > > > > > You can

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-04 Thread RVP
On Sat, 4 Nov 2023, tlaro...@kergis.com wrote: No...: this is a break of existing. Trailing `*' selects STARred devices (I'm not the inventor of this). So `*' can not be used as a joker ;-) You can allow escapes for those: uc> disable i915drmkms\* # exact match STARred uc> disable

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-04 Thread tlaronde
On Sat, Nov 04, 2023 at 08:31:09AM +, RVP wrote: > On Sat, 4 Nov 2023, tlaro...@kergis.com wrote: > > > > 1) Allowing shell-like patterns (not hard to implement): > > > > > > uc> disable drm* # all starting with `drm' > > > > No...: this is a break of existing. Trailing `*' selects STARred

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-04 Thread tlaronde
On Sat, Nov 04, 2023 at 08:20:43AM +, Michael van Elst wrote: > tlaro...@kergis.com writes: > > >disable {drmkms} # NEW: disable devices belonging to group "drmkms" > > Almost noone would need to turn off all drmkms drivers. What you may > want to control is that a GPU isn't used as a

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-04 Thread RVP
On Sat, 4 Nov 2023, tlaro...@kergis.com wrote: 1) Allowing shell-like patterns (not hard to implement): uc> disable drm* # all starting with `drm' No...: this is a break of existing. Trailing `*' selects STARred devices (I'm not the inventor of this). So `*' can not be used as a joker

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-04 Thread Michael van Elst
tlaro...@kergis.com writes: >disable {drmkms} # NEW: disable devices belonging to group "drmkms" Almost noone would need to turn off all drmkms drivers. What you may want to control is that a GPU isn't used as a console. Disabling a driver is just our crude workaround to achieve this. I

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-04 Thread Michael van Elst
r...@sdf.org (RVP) writes: >On Sat, 4 Nov 2023, RVP wrote: >> 1) Allowing shell-like patterns (not hard to implement): >> >> uc> disable *drm* *usb$ # all with `drm' anywhere and those ending in >> >Ah, since these are shell-like patterns there's not need for a `$' to >denote EOL. So:

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-04 Thread tlaronde
On Sat, Nov 04, 2023 at 07:41:19AM +, RVP wrote: > On Sat, 4 Nov 2023, tlaro...@kergis.com wrote: > > > - 1) No change to the general form of current syntax; > > > > - 2) Selection can be as presently: by number (index in cfdata), by > > name (driver name), but also (NEW) by pattern: a

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-04 Thread RVP
On Sat, 4 Nov 2023, RVP wrote: 1) Allowing shell-like patterns (not hard to implement): uc> disable *drm* *usb$ # all with `drm' anywhere and those ending in Ah, since these are shell-like patterns there's not need for a `$' to denote EOL. So: uc> disable *drm* *usb # all

Re: [RFC 2] userconf(4): 2nd proposal

2023-11-04 Thread RVP
On Sat, 4 Nov 2023, tlaro...@kergis.com wrote: - 1) No change to the general form of current syntax; - 2) Selection can be as presently: by number (index in cfdata), by name (driver name), but also (NEW) by pattern: a pattern is between slashes, it is a fix substring, that can be optionnally