freebsd-dev/sys/dev/atkbdc
Conrad Meyer 893daee680 psm(4): Always initialize used values in debug print
'status' array passed to get_mouse_status() is usually uninitialized by
callers.

Fully populating it with values in get_mouse_status() can fail due to
read_aux_data().

Additionally, nothing in API constrains 'len' to be >= 3.  In practice,
every caller passes three, so perhaps that argument should just be removed.
Refactoring is a larger change, though.

Remove use of potentially uninitialized values by:
1. Only printing 3 debug statuses if the passed array was at least
   'len' >= 3;
2. Populating 'status' array up to first three elements, if read_aux_data()
   failed.

No functional change intended.

Reported by:	Coverity
Sponsored by:	Dell EMC Isilon
2018-03-01 00:58:59 +00:00
..
atkbd_atkbdc.c sys/dev: further adoption of SPDX licensing ID tags. 2017-11-27 14:52:40 +00:00
atkbd.c sys/dev: further adoption of SPDX licensing ID tags. 2017-11-27 14:52:40 +00:00
atkbdc_ebus.c sys/dev: further adoption of SPDX licensing ID tags. 2017-11-27 14:52:40 +00:00
atkbdc_isa.c Create a new ISA_PNP_INFO macro. Use this macro every where we have 2017-12-23 06:49:27 +00:00
atkbdc_subr.c sys/dev: further adoption of SPDX licensing ID tags. 2017-11-27 14:52:40 +00:00
atkbdc_subr.h sys/dev: further adoption of SPDX licensing ID tags. 2017-11-27 14:52:40 +00:00
atkbdc.c sys/dev: further adoption of SPDX licensing ID tags. 2017-11-27 14:52:40 +00:00
atkbdcreg.h sys/dev: further adoption of SPDX licensing ID tags. 2017-11-27 14:52:40 +00:00
atkbdreg.h sys/dev: further adoption of SPDX licensing ID tags. 2017-11-27 14:52:40 +00:00
psm.c psm(4): Always initialize used values in debug print 2018-03-01 00:58:59 +00:00
psm.h