Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/usb disable inlining for couple functions which allo...
details: https://anonhg.NetBSD.org/src/rev/65bd7cadb6fb
branches: trunk
changeset: 973241:65bd7cadb6fb
user: jdolecek <jdolecek%NetBSD.org@localhost>
date: Wed Jun 24 21:06:39 2020 +0000
description:
disable inlining for couple functions which allocate usb_device_request_t
on stack to reduce total run_init() stack usage from 7KB to 2KB
diffstat:
sys/dev/usb/if_run.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diffs (54 lines):
diff -r f9db167f3556 -r 65bd7cadb6fb sys/dev/usb/if_run.c
--- a/sys/dev/usb/if_run.c Wed Jun 24 20:17:55 2020 +0000
+++ b/sys/dev/usb/if_run.c Wed Jun 24 21:06:39 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: if_run.c,v 1.41 2020/06/11 09:56:57 martin Exp $ */
+/* $NetBSD: if_run.c,v 1.42 2020/06/24 21:06:39 jdolecek Exp $ */
/* $OpenBSD: if_run.c,v 1.90 2012/03/24 15:11:04 jsg Exp $ */
/*-
@@ -23,7 +23,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_run.c,v 1.41 2020/06/11 09:56:57 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_run.c,v 1.42 2020/06/24 21:06:39 jdolecek Exp $");
#ifdef _KERNEL_OPT
#include "opt_usb.h"
@@ -931,7 +931,7 @@
}
}
-static int
+static int __noinline
run_load_microcode(struct run_softc *sc)
{
usb_device_request_t req;
@@ -1003,7 +1003,7 @@
return 0;
}
-static int
+static int __noinline
run_reset(struct run_softc *sc)
{
usb_device_request_t req;
@@ -1016,7 +1016,7 @@
return usbd_do_request(sc->sc_udev, &req, NULL);
}
-static int
+static int __noinline
run_read(struct run_softc *sc, uint16_t reg, uint32_t *val)
{
uint32_t tmp;
@@ -1056,7 +1056,7 @@
return usbd_do_request(sc->sc_udev, &req, NULL);
}
-static int
+static int __noinline
run_write(struct run_softc *sc, uint16_t reg, uint32_t val)
{
uint32_t tmp = htole32(val);
Home |
Main Index |
Thread Index |
Old Index