factor out ipv4 and ipv6 initial packet sanity checks for bridges

2021-05-30 Thread David Gwynne
if you're looking at an ip header, it makes sense to do some checks to make sure that the values and addresses make some sense. the canonical versions of these checks are in the ipv4 and ipv6 input paths, which makes sense. when bridge(4) is about to run packets through pf it makes sure the ip

Re: usbhidctl: add -R flag to dump raw report descriptor bytes

2021-05-30 Thread joshua stein
On Fri, 28 May 2021 at 21:52:57 -0500, joshua stein wrote: > > Another approach which keeps the structure opaque is the extend the > > usbhid(3) API with something like: > > > > void > > hid_get_report_desc_data(report_desc_t d, uint8_t **data, uint32_t > > *size) > > { > >

Re: ftpd(8): Convert K function definitions to modern C

2021-05-30 Thread Todd C . Miller
On Sun, 30 May 2021 17:47:34 +0200, Jan Klemkow wrote: > Convert K function definitions to modern C. OK millert@ - todd

Re: iwm: avoid 'mac clock not ready' panic

2021-05-30 Thread Mark Kettenis
> Date: Sun, 30 May 2021 22:26:09 +0200 > From: Stefan Sperling > > Steven observed a panic ("iwm0: mac clock not ready") while testing > the iwm firmware update patch on a 9560 device. > I've also seen this happen one time, at some point during development. > > In hindsight it is a bad idea to

iwm: avoid 'mac clock not ready' panic

2021-05-30 Thread Stefan Sperling
Steven observed a panic ("iwm0: mac clock not ready") while testing the iwm firmware update patch on a 9560 device. I've also seen this happen one time, at some point during development. In hindsight it is a bad idea to look at hardware register state here. The point of iwm_nic_assert_locked() is

ftpd(8): Convert K function definitions to modern C

2021-05-30 Thread Jan Klemkow
Hi, Convert K function definitions to modern C. OK? bye, Jan Index: ftpcmd.y === RCS file: /cvs/src/libexec/ftpd/ftpcmd.y,v retrieving revision 1.72 diff -u -p -r1.72 ftpcmd.y --- ftpcmd.y23 May 2021 17:01:21 - 1.72

couple devices found on a intel nuc 10i7FNH

2021-05-30 Thread Felix Kronlage-Dammers
ahoi, recognize couple devices found in a Intel Nuc 10i7FNH. Since the JHL7540 exists with a few pci ids, this suffixes the existing one so it matches with the new addition. felix Index: sys/dev/pci/pcidevs === RCS file:

Re: Avoid shifting of a negative value in sys_adjfreq()

2021-05-30 Thread Christian Weisgerber
Visa Hankala: > However, wouldn't it be better if the code avoided the > situation, for example by defining ADJFREQ_MIN as the negative > of ADJFREQ_MAX? Indeed it would. ok naddy@ > --- kern/kern_time.c 23 Dec 2020 20:45:02 - 1.151 > +++ kern/kern_time.c 30 May 2021 15:38:09 -

Avoid shifting of a negative value in sys_adjfreq()

2021-05-30 Thread Visa Hankala
When cross-compiling the kernel using ports clang (tsk tsk), the compiler reports the following: src/sys/kern/kern_time.c:418:11: error: shifting a negative signed value is undefined [-Werror,-Wshift-negative-value] if (f < ADJFREQ_MIN || f > ADJFREQ_MAX)

Re: uvideo(4) new quirk flag UVIDEO_FLAG_NOATTACH

2021-05-30 Thread Marcus Glocker
On Mon, 5 Apr 2021 23:54:31 +0200 Marcus Glocker wrote: > On Mon, Apr 05, 2021 at 11:27:10PM +0200, Mark Kettenis wrote: > > [...] > > > > > > How common is it to explain the system behavior in cases like > > > > > this? Would it be less surprising (generate less misc@ > > > > > traffic) if we

Re: usbhidctl: add -R flag to dump raw report descriptor bytes

2021-05-30 Thread Theo Buehler
On Fri, May 28, 2021 at 09:52:57PM -0500, joshua stein wrote: > On Wed, 26 May 2021 at 08:13:52 +0200, Anton Lindqvist wrote: > > On Tue, May 25, 2021 at 08:31:14AM +0200, Anton Lindqvist wrote: > > > On Mon, May 24, 2021 at 09:17:26AM -0500, joshua stein wrote: > > > > This is useful for parsing

Re: usbhidctl: add -R flag to dump raw report descriptor bytes

2021-05-30 Thread Anton Lindqvist
On Fri, May 28, 2021 at 09:52:57PM -0500, joshua stein wrote: > On Wed, 26 May 2021 at 08:13:52 +0200, Anton Lindqvist wrote: > > On Tue, May 25, 2021 at 08:31:14AM +0200, Anton Lindqvist wrote: > > > On Mon, May 24, 2021 at 09:17:26AM -0500, joshua stein wrote: > > > > This is useful for parsing