Re: Lock operations for knote lists

2020-12-11 Thread David Gwynne
On Fri, Dec 11, 2020 at 05:37:57PM +, Visa Hankala wrote: > This patch extends struct klist with a callback descriptor and > an argument. The main purpose of this is to let the kqueue subsystem > assert when a klist should be locked, and operate the klist lock > in klist_invalidate(). i've alw

Re: Poison file names

2020-12-11 Thread Theo de Raadt
I'd be ok with renames of all of them. It is really weird that portable filenames aren't just 255 characters avoiding NUL or path-separator (usually /). This is not about msdos alone. The implication has slowly infected other systems and applications -- which now make logical decisions, and thos

Re: Poison file names

2020-12-11 Thread Jonathan Gray
On Fri, Dec 11, 2020 at 11:58:10AM -0700, jo...@armadilloaerospace.com wrote: > I would like to be able to clone the github mirror on windows. I do > wind up > using 7z on the tar file as a workaround, but it would be nice if github > "just worked". The com files is what the clone fails on, and t

Re: Adding -p to pr(1)

2020-12-11 Thread Andras Farkas
On Fri, Dec 11, 2020 at 10:23 PM Andras Farkas wrote: > Also, I think the line: > ttyinf = stdin; > is almost certainly unnecessary. But I'd like someone else more > versed in programming to confirm this. I don't think ttyinf's value > of stdin is ever used, as it gets set next to /dev/tty I no

Re: Adding -p to pr(1)

2020-12-11 Thread Andras Farkas
Also, I think the line: ttyinf = stdin; is almost certainly unnecessary. But I'd like someone else more versed in programming to confirm this. I don't think ttyinf's value of stdin is ever used, as it gets set next to /dev/tty On Fri, Dec 11, 2020 at 9:54 PM Andras Farkas wrote: > > Hi! > > Aft

Adding -p to pr(1)

2020-12-11 Thread Andras Farkas
Hi! After seeing the diff for cat -n earlier today, and just browsing Unix stuff on my own, I noticed OpenBSD's pr(1) command has no -p option despite pr.1 stating: > The pr utility is compliant with the IEEE Std 1003.1-2008 ("POSIX.1") > specification. https://man.openbsd.org/pr.1 This part of t

i386: apm(4): apm_thread(): sleep without lbolt

2020-12-11 Thread Scott Cheloha
Here's another sleep that doesn't need lbolt. The idea here is to call apm_periodic_check() once a second. We can do that without lbolt. Is there some other address that would be more appropriate for this thread to sleep on? It doesn't look like any apm(4) code calls wakeup(9) on lbolt so I've j

sdmmc(4): sdmmc_io_function_enable(): don't sleep on lbolt

2020-12-11 Thread Scott Cheloha
Hi, I'd like to remove lbolt from the kernel. I think having it in the kernel complicates otherwise simple code. We can start with sdmmc(4). The goal in sdmmc_io_function_enable() is calling sdmmc_io_function_ready() up to six times and sleep 1 second between each attempt. Here's rewritten cod

Re: diff: refactor MCLGETI() macro

2020-12-11 Thread David Gwynne
On Wed, Oct 07, 2020 at 10:44:15PM +0200, Jan Klemkow wrote: > Hi, > > The name of the macro MCLGETI obsolete. It was made to use a network > interface pointer inside. But, now it is just used to define a special > length and the interface pointer is discarded. > > Thus, the following diff rena

clear mbuf timestamp when it leaves the stack

2020-12-11 Thread David Gwynne
an mbuf timestamp is set by hw when a packet is rxed, and is then used by the socket layer and things like ntpd, but is also used by bpf when it provides packet timestamps. the timestamp is only valid on rxed packets though. when they leave the stack they should not be used anymore. on the way out

Re: pool(9): remove ticks (attempt 2)

2020-12-11 Thread Scott Cheloha
On Fri, Dec 11, 2020 at 07:52:45PM +0100, Mark Kettenis wrote: > > Date: Fri, 11 Dec 2020 11:51:54 -0600 > > From: Scott Cheloha > > > > On Fri, Dec 11, 2020 at 09:49:07AM -0300, Martin Pieuchot wrote: > > > > > > I'm not sure to understand, can't we do: > > > > > > pool_wait_free = SEC_TO_NS

Re: Poison file names

2020-12-11 Thread johnc
I would like to be able to clone the github mirror on windows. I do wind up using 7z on the tar file as a workaround, but it would be nice if github "just worked". The com files is what the clone fails on, and those seemed easy enough to address, but if it is actually a deep rat hole, I certainly

Re: delays in sensors thread

2020-12-11 Thread Marcus Glocker
On Fri, Dec 11, 2020 at 10:01:35AM +0100, Alexandre Ratchov wrote: > On Fri, Dec 11, 2020 at 09:07:45AM +0100, Marcus Glocker wrote: > > > > After doing some deeper analyzes in to asmc_wait() I agree to that. > > Something seems to go fundamental wrong there. In every asmc_update() > > execution

Re: pool(9): remove ticks (attempt 2)

2020-12-11 Thread Mark Kettenis
> Date: Fri, 11 Dec 2020 11:51:54 -0600 > From: Scott Cheloha > > On Fri, Dec 11, 2020 at 09:49:07AM -0300, Martin Pieuchot wrote: > > On 11/12/20(Fri) 12:52, Mark Kettenis wrote: > > > > Date: Thu, 10 Dec 2020 16:13:22 -0600 > > > > From: Scott Cheloha > > > > > > > > Hi, > > > > > > > > We l

Re: pool(9): remove ticks (attempt 2)

2020-12-11 Thread Scott Cheloha
On Fri, Dec 11, 2020 at 09:49:07AM -0300, Martin Pieuchot wrote: > On 11/12/20(Fri) 12:52, Mark Kettenis wrote: > > > Date: Thu, 10 Dec 2020 16:13:22 -0600 > > > From: Scott Cheloha > > > > > > Hi, > > > > > > We looked at removing the ticks from subr_pool.c a while back but it > > > got shelved

Lock operations for knote lists

2020-12-11 Thread Visa Hankala
This patch extends struct klist with a callback descriptor and an argument. The main purpose of this is to let the kqueue subsystem assert when a klist should be locked, and operate the klist lock in klist_invalidate(). Access to a knote list of a kqueue-monitored object has to be serialized someh

Re: Poison file names

2020-12-11 Thread Daniel Dickman
On Wed, Dec 9, 2020 at 4:50 AM Jonathan Gray wrote: > > On Tue, Dec 08, 2020 at 11:36:37PM -0700, jo...@armadilloaerospace.com wrote: > > The game battlestar has source files names com1.c through com7.c, which > > are illegal on windows due to ancient dos com port rules. > > > > I understand there

Re: bpf(4): BIOCGRTIMEOUT, BIOCSRTIMEOUT: protect with bd_mtx

2020-12-11 Thread Claudio Jeker
On Thu, Dec 10, 2020 at 11:26:16AM -0600, Scott Cheloha wrote: > Hi, > > Before converting bpf(4) from using ticks to using real units of time > we need to serialize BIOCGRTIMEOUT and BIOCSRTIMEOUT. Neither > operation is atomic so we need to use the per-descriptor mutex when > reading or writing

Re: pool(9): remove ticks (attempt 2)

2020-12-11 Thread Martin Pieuchot
On 11/12/20(Fri) 12:52, Mark Kettenis wrote: > > Date: Thu, 10 Dec 2020 16:13:22 -0600 > > From: Scott Cheloha > > > > Hi, > > > > We looked at removing the ticks from subr_pool.c a while back but it > > got shelved. That may or may not have been my fault. I don't > > remember. > > > > Anyway

Re: Switch select(2) to kqueue-based implementation

2020-12-11 Thread Martin Pieuchot
On 10/12/20(Thu) 09:59, Martin Pieuchot wrote: > All previous kqueue refactoring have been committed, here's a final diff > to modify the internal implementation of {p,}select(2) to query kqfilter > handlers instead of poll ones. > > {p,}poll(2) are left untouched to ease the transition. > > Here

Re: Port httpd(8) 'strip' directive to relayd(8)

2020-12-11 Thread Olivier Cherrier
Hello tech@, Is there any interest for this feature to be commited? I find it very useful. Thank you Denis! -- Olivier Cherrier Phone: +352691570680 mailto:o...@symacx.com On Sun, Oct 25, 2020 at 11:28:10AM +0100, open...@ledeuns.net wrote: > Date: Sun, 25 Oct 2020 11:28:10 +0100 > Fr

Re: pool(9): remove ticks (attempt 2)

2020-12-11 Thread Mark Kettenis
> Date: Thu, 10 Dec 2020 16:13:22 -0600 > From: Scott Cheloha > > Hi, > > We looked at removing the ticks from subr_pool.c a while back but it > got shelved. That may or may not have been my fault. I don't > remember. > > Anyway, I would normally suggest switching to getuptime(9) here, but >

Re: ipmi(4): ipmi_poll_thread(): tsleep(9) -> tsleep_nsec(9)

2020-12-11 Thread Claudio Jeker
On Thu, Dec 10, 2020 at 10:07:29PM -0600, Scott Cheloha wrote: > On Thu, Dec 10, 2020 at 10:00:46AM +0100, Claudio Jeker wrote: > > On Mon, Dec 07, 2020 at 10:54:26PM -0600, Scott Cheloha wrote: > > > Index: ipmi.c > > > === > > > RCS

Re: delays in sensors thread

2020-12-11 Thread Alexandre Ratchov
On Fri, Dec 11, 2020 at 09:07:45AM +0100, Marcus Glocker wrote: > > After doing some deeper analyzes in to asmc_wait() I agree to that. > Something seems to go fundamental wrong there. In every asmc_update() > execution, I can see asmc_wait() timeout 9 times, always on the > ASMC_ACCEPT check. T

Re: delays in sensors thread

2020-12-11 Thread Marcus Glocker
On Thu, Dec 10, 2020 at 06:06:26PM -0300, Martin Pieuchot wrote: > On 10/12/20(Thu) 21:40, Alexandre Ratchov wrote: > > On Thu, Dec 10, 2020 at 05:27:16PM +0100, Marcus Glocker wrote: > > > Hi All, > > > > > > I recently started to play around with uvideo(4) and uaudio(4) on my > > > amd64 iMacs.