HomeFreeBSD

pci: Fix pci_host_generic_acpi with gcc

Description

pci: Fix pci_host_generic_acpi with gcc

In pci_host_generic_acpi.c we loop over pci_acpi_quirks to check if
we need to handle any quirks. GCC doesn't like the terminatin as it
sets a fixed width string to 0.

As this the array is only ever used in this file change to use nitems
to find when to stop the loop.

Reviewed by: brooks, imp, jhb, emaste
Sponsored by: Arm Ltd
Differential Revision: https://reviews.freebsd.org/D45265

(cherry picked from commit f55e866488ba2d8bb5b79659ee84bec1fe7808fb)

Details

Provenance
andrewAuthored on May 22 2024, 8:19 AM
Reviewer
brooks
Differential Revision
D45265: pci: Fix pci_host_generic_acpi with gcc
Parents
rG29f8816b668b: arm64/rockchip: Fix the build with GCC
Branches
Unknown
Tags
Unknown