Module Name: src Committed By: andvar Date: Mon Dec 11 22:29:39 UTC 2023
Modified Files: src/sys/arch/sparc/dev: fd.c Log Message: Surround fdc declaration and definition with FD_DEBUG blocks. FD_DEBUG is defined by default, thus build passes, however would fail otherwise since it is only used in debug block. To generate a diff of this commit: cvs rdiff -u -r1.163 -r1.164 src/sys/arch/sparc/dev/fd.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/sparc/dev/fd.c diff -u src/sys/arch/sparc/dev/fd.c:1.163 src/sys/arch/sparc/dev/fd.c:1.164 --- src/sys/arch/sparc/dev/fd.c:1.163 Sat Aug 7 16:19:05 2021 +++ src/sys/arch/sparc/dev/fd.c Mon Dec 11 22:29:39 2023 @@ -1,4 +1,4 @@ -/* $NetBSD: fd.c,v 1.163 2021/08/07 16:19:05 thorpej Exp $ */ +/* $NetBSD: fd.c,v 1.164 2023/12/11 22:29:39 andvar Exp $ */ /*- * Copyright (c) 2000 The NetBSD Foundation, Inc. @@ -101,7 +101,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: fd.c,v 1.163 2021/08/07 16:19:05 thorpej Exp $"); +__KERNEL_RCSID(0, "$NetBSD: fd.c,v 1.164 2023/12/11 22:29:39 andvar Exp $"); #include "opt_ddb.h" #include "opt_md.h" @@ -1948,7 +1948,9 @@ int fdioctl(dev_t dev, u_long cmd, void *addr, int flag, struct lwp *l) { struct fd_softc *fd; +#ifdef FD_DEBUG struct fdc_softc *fdc; +#endif struct fdformat_parms *form_parms; struct fdformat_cmd *form_cmd; struct ne7_fd_formb *fd_formb; @@ -1962,7 +1964,9 @@ fdioctl(dev_t dev, u_long cmd, void *add return (ENXIO); fd = device_lookup_private(&fd_cd, FDUNIT(dev)); +#ifdef FD_DEBUG fdc = device_private(device_parent(fd->sc_dv)); +#endif switch (cmd) { case DIOCGDINFO: