opnsense-src/sys/dev/usb/net
Mark Johnston 030cbcc4c2 if_urndis: Organize buffer layouts more naturally
- Group the request header and I/O buffer in one structure, rather than
  assuming that both request structures have the same size.
- Pass a pointer to the whole structure to urndis_ctrl_query() and
  urndis_ctrl_set() rather than just the header.  Otherwise, on CHERI
  platforms, these functions violate subobject bounds since they modify
  the buffer following the header.

While here, there is no apparent reason for the request structure used
in urndis_attach() to be allocated statically.  Change it so that it's
allocated on the stack.

No functional change intended.

Reviewed by:	jhb
MFC after:	2 weeks
Sponsored by:	Innovate UK
Differential Revision:	https://reviews.freebsd.org/D45866

(cherry picked from commit 5dc4682c32691b9d0a20abdc5479d6ce2b36915e)
2024-07-23 09:01:37 -04:00
..
if_aue.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
if_auereg.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
if_axe.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
if_axereg.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
if_axge.c axge: Add support for AX88179A 2023-10-11 09:16:14 -04:00
if_axgereg.h axge: Add support for AX88179A 2023-10-11 09:16:14 -04:00
if_cdce.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
if_cdceem.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
if_cdcereg.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
if_cue.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
if_cuereg.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
if_ipheth.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
if_iphethvar.h sys: Remove $FreeBSD$: one-line .c comment pattern 2023-08-16 11:54:24 -06:00
if_kue.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
if_kuefw.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
if_kuereg.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
if_mos.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
if_mosreg.h sys: Remove $FreeBSD$: one-line .c comment pattern 2023-08-16 11:54:24 -06:00
if_muge.c muge(4): Fix a typo in a source code comment 2024-04-21 09:33:29 +02:00
if_mugereg.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
if_rue.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
if_ruereg.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
if_smsc.c smsc(4): update to mention Microchip 2024-05-10 09:01:52 -04:00
if_smscreg.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
if_udav.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
if_udavreg.h sys: Remove $FreeBSD$: one-line .c comment pattern 2023-08-16 11:54:24 -06:00
if_ure.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
if_urereg.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
if_urndis.c if_urndis: Organize buffer layouts more naturally 2024-07-23 09:01:37 -04:00
if_urndisreg.h sys: Remove $FreeBSD$: one-line .c comment pattern 2023-08-16 11:54:24 -06:00
if_usie.c net: Remove unneeded NULL check for the allocated ifnet 2024-07-12 20:03:37 +08:00
if_usievar.h sys: Remove $FreeBSD$: one-line .c comment pattern 2023-08-16 11:54:24 -06:00
ruephy.c sys: Remove $FreeBSD$: one-line .c pattern 2023-08-16 11:54:36 -06:00
ruephyreg.h sys: Remove $FreeBSD$: two-line .h pattern 2023-08-16 11:54:11 -06:00
uhso.c net: Remove unneeded NULL check for the allocated ifnet 2024-07-12 20:03:37 +08:00
usb_ethernet.c net: Remove unneeded NULL check for the allocated ifnet 2024-07-12 20:03:37 +08:00
usb_ethernet.h sys: Remove $FreeBSD$: one-line .c comment pattern 2023-08-16 11:54:24 -06:00