NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

PR/61015 CVS commit: src/sys/dev/acpi



The following reply was made to PR kern/61015; it has been noted by GNATS.

From: "Taylor R Campbell" <riastradh%netbsd.org@localhost>
To: gnats-bugs%gnats.NetBSD.org@localhost
Cc: 
Subject: PR/61015 CVS commit: src/sys/dev/acpi
Date: Fri, 20 Nov 2026 15:32:53 +0000

 Module Name:	src
 Committed By:	riastradh
 Date:		Fri Nov 20 15:32:53 UTC 2026
 
 Modified Files:
 	src/sys/dev/acpi: pckbc_acpi.c
 
 Log Message:
 pckbc(4) at acpi: Fix build with -Os.
 
 Fixes:
 
 /home/riastradh/netbsd/current/src/sys/dev/acpi/pckbc_acpi.c: In function 'pckbc_acpi_intr_establish':
 /home/riastradh/netbsd/current/src/sys/dev/acpi/pckbc_acpi.c:242:63: error: 'handle' may be used uninitialized [-Werror=maybe-uninitialized]
   242 |                 rv = acpi_intr_establish(sc->sc_dv, (uint64_t)(uintptr_t)handle,
       |                                                               ^~~~~~~~~~~~~~~~~
 /home/riastradh/netbsd/current/src/sys/dev/acpi/pckbc_acpi.c:224:21: note: 'handle' was declared here
   224 |         ACPI_HANDLE handle;
       |                     ^~~~~~
 
 No functional change intended -- the code wasn't _wrong_ before; this
 just makes it clearer, with less analysis effort, that handle is
 initialized in the path in question.
 
 While here, rename local variable `rv' to `ih' to make it clearer
 what it is (not just some arbitrary return value of a subroutine but
 specifically an interrupt handler cookie).
 
 PR kern/61015: sys/dev/acpi/pckbc_acpi.c:242:63: error: 'handle' may
 be used uninitialized
 
 
 To generate a diff of this commit:
 cvs rdiff -u -r1.40 -r1.41 src/sys/dev/acpi/pckbc_acpi.c
 
 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.
 



Home | Main Index | Thread Index | Old Index