git: e34dce0f7be4 - stable/14 - pci_user.c: Cosmetic fixes
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 27 Dec 2024 17:06:19 UTC
The branch stable/14 has been updated by jhb:
URL: https://cgit.FreeBSD.org/src/commit/?id=e34dce0f7be4cfb39c369ec1cf1fa6145f02e5ac
commit e34dce0f7be4cfb39c369ec1cf1fa6145f02e5ac
Author: John Baldwin <jhb@FreeBSD.org>
AuthorDate: 2024-11-13 16:07:03 +0000
Commit: John Baldwin <jhb@FreeBSD.org>
CommitDate: 2024-12-27 15:29:23 +0000
pci_user.c: Cosmetic fixes
Correct leading whitespace for a few lines.
Consistently use more canonical #ifdef to test for COMPAT_FREEBSD32.
Obtained from: CheriBSD
Sponsored by: AFRL, DARPA
(cherry picked from commit 727de621c5f07681034eed2d6ce3662a8239e987)
---
sys/dev/pci/pci_user.c | 28 ++++++++++++++--------------
1 file changed, 14 insertions(+), 14 deletions(-)
diff --git a/sys/dev/pci/pci_user.c b/sys/dev/pci/pci_user.c
index cdb893efa950..a81044ff3c43 100644
--- a/sys/dev/pci/pci_user.c
+++ b/sys/dev/pci/pci_user.c
@@ -692,7 +692,7 @@ pci_conf_size(u_long cmd)
static void
pci_conf_io_init(struct pci_conf_io *cio, caddr_t data, u_long cmd)
{
-#if defined(COMPAT_FREEBSD32)
+#ifdef COMPAT_FREEBSD32
struct pci_conf_io32 *cio32;
#endif
@@ -709,17 +709,17 @@ pci_conf_io_init(struct pci_conf_io *cio, caddr_t data, u_long cmd)
#ifdef PRE7_COMPAT
case PCIOCGETCONF_OLD32:
#endif
- cio32 = (struct pci_conf_io32 *)data;
- cio->pat_buf_len = cio32->pat_buf_len;
- cio->num_patterns = cio32->num_patterns;
- cio->patterns = (void *)(uintptr_t)cio32->patterns;
- cio->match_buf_len = cio32->match_buf_len;
- cio->num_matches = cio32->num_matches;
- cio->matches = (void *)(uintptr_t)cio32->matches;
- cio->offset = cio32->offset;
- cio->generation = cio32->generation;
- cio->status = cio32->status;
- return;
+ cio32 = (struct pci_conf_io32 *)data;
+ cio->pat_buf_len = cio32->pat_buf_len;
+ cio->num_patterns = cio32->num_patterns;
+ cio->patterns = (void *)(uintptr_t)cio32->patterns;
+ cio->match_buf_len = cio32->match_buf_len;
+ cio->num_matches = cio32->num_matches;
+ cio->matches = (void *)(uintptr_t)cio32->matches;
+ cio->offset = cio32->offset;
+ cio->generation = cio32->generation;
+ cio->status = cio32->status;
+ return;
#endif
default:
@@ -733,7 +733,7 @@ pci_conf_io_update_data(const struct pci_conf_io *cio, caddr_t data,
u_long cmd)
{
struct pci_conf_io *d_cio;
-#if defined(COMPAT_FREEBSD32)
+#ifdef COMPAT_FREEBSD32
struct pci_conf_io32 *cio32;
#endif
@@ -1172,7 +1172,7 @@ pci_ioctl(struct cdev *dev, u_long cmd, caddr_t data, int flag, struct thread *t
*/
cio->status = PCI_GETCONF_ERROR;
error = EINVAL;
- goto getconfexit;
+ goto getconfexit;
}
/*