Skip to content

Commit

Permalink
Supply missing header guards
Browse files Browse the repository at this point in the history
Signed-off-by: Markus Armbruster <[email protected]>
Message-Id: <[email protected]>
  • Loading branch information
Markus Armbruster committed Jun 12, 2019
1 parent 37677d7 commit f91005e
Show file tree
Hide file tree
Showing 84 changed files with 419 additions and 7 deletions.
6 changes: 5 additions & 1 deletion hw/9pfs/xen-9pfs.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,11 @@
*
* This work is licensed under the terms of the GNU GPL version 2 or
* later. See the COPYING file in the top-level directory.
*
*/

#ifndef HW_9PFS_XEN_9PFS_H
#define HW_9PFS_XEN_9PFS_H

#include <xen/io/protocols.h>
#include "hw/xen/io/ring.h"

Expand All @@ -19,3 +21,5 @@
* inline functions in c files.
*/
DEFINE_XEN_FLEX_RING_AND_INTF(xen_9pfs);

#endif
5 changes: 5 additions & 0 deletions hw/hppa/hppa_hardware.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
/* HPPA cores and system support chips. */

#ifndef HW_HPPA_HPPA_HARDWARE_H
#define HW_HPPA_HPPA_HARDWARE_H

#define FIRMWARE_START 0xf0000000
#define FIRMWARE_END 0xf0800000

Expand Down Expand Up @@ -38,3 +41,5 @@

#define HPPA_MAX_CPUS 8 /* max. number of SMP CPUs */
#define CPU_CLOCK_MHZ 250 /* emulate a 250 MHz CPU */

#endif
4 changes: 4 additions & 0 deletions hw/input/adb-internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@
* THE SOFTWARE.
*/

#ifndef HW_INPUT_ADB_INTERNAL_H
#define HW_INPUT_ADB_INTERNAL_H

/* ADB commands */

#define ADB_BUSRESET 0x00
Expand All @@ -47,3 +50,4 @@

extern const VMStateDescription vmstate_adb_device;

#endif
5 changes: 5 additions & 0 deletions hw/net/e1000e_core.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@
* License along with this library; if not, see <http://www.gnu.org/licenses/>.
*/

#ifndef HW_NET_E1000E_CORE_H
#define HW_NET_E1000E_CORE_H

#define E1000E_PHY_PAGE_SIZE (0x20)
#define E1000E_PHY_PAGES (0x07)
#define E1000E_MAC_SIZE (0x8000)
Expand Down Expand Up @@ -151,3 +154,5 @@ e1000e_receive_iov(E1000ECore *core, const struct iovec *iov, int iovcnt);

void
e1000e_start_recv(E1000ECore *core);

#endif
5 changes: 5 additions & 0 deletions hw/net/e1000x_common.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@
* License along with this library; if not, see <http://www.gnu.org/licenses/>.
*/

#ifndef HW_NET_E1000X_COMMON_H
#define HW_NET_E1000X_COMMON_H

#include "e1000_regs.h"

#define defreg(x) x = (E1000_##x >> 2)
Expand Down Expand Up @@ -209,3 +212,5 @@ typedef struct e1000x_txd_props {

void e1000x_read_tx_ctx_descr(struct e1000_context_desc *d,
e1000x_txd_props *props);

#endif
6 changes: 5 additions & 1 deletion hw/net/vmxnet3_defs.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,11 @@
*
* This work is licensed under the terms of the GNU GPL, version 2.
* See the COPYING file in the top-level directory.
*
*/

#ifndef HW_NET_VMXNET3_DEFS_H
#define HW_NET_VMXNET3_DEFS_H

#include "net/net.h"
#include "hw/net/vmxnet3.h"

Expand Down Expand Up @@ -131,3 +133,5 @@ typedef struct {
/* Compatibility flags for migration */
uint32_t compat_flags;
} VMXNET3State;

#endif
5 changes: 5 additions & 0 deletions hw/usb/hcd-xhci.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@
* License along with this library; if not, see <http://www.gnu.org/licenses/>.
*/

#ifndef HW_USB_HCD_XHCI_H
#define HW_USB_HCD_XHCI_H

#define TYPE_XHCI "base-xhci"
#define TYPE_NEC_XHCI "nec-usb-xhci"
#define TYPE_QEMU_XHCI "qemu-xhci"
Expand Down Expand Up @@ -225,3 +228,5 @@ struct XHCIState {

bool nec_quirks;
};

#endif
5 changes: 5 additions & 0 deletions hw/usb/quirks.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@
* (at your option) any later version.
*/

#ifndef HW_USB_QUIRKS_H
#define HW_USB_QUIRKS_H

/* 1 on 1 copy of linux/drivers/usb/serial/ftdi_sio_ids.h */
#include "quirks-ftdi-ids.h"
/* 1 on 1 copy of linux/drivers/usb/serial/pl2303.h */
Expand Down Expand Up @@ -908,3 +911,5 @@ static const struct usb_device_id usbredir_ftdi_serial_ids[] = {

#undef USB_DEVICE
#undef USB_DEVICE_AND_INTERFACE_INFO

#endif
5 changes: 5 additions & 0 deletions include/fpu/softfloat-macros.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,9 @@ this code that are retained.
* version 2 or later. See the COPYING file in the top-level directory.
*/

#ifndef FPU_SOFTFLOAT_MACROS_H
#define FPU_SOFTFLOAT_MACROS_H

/*----------------------------------------------------------------------------
| Shifts `a' right by the number of bits given in `count'. If any nonzero
| bits are shifted off, they are ``jammed'' into the least significant bit of
Expand Down Expand Up @@ -796,3 +799,5 @@ static inline flag ne128( uint64_t a0, uint64_t a1, uint64_t b0, uint64_t b1 )
return ( a0 != b0 ) || ( a1 != b1 );

}

#endif
5 changes: 5 additions & 0 deletions include/hw/arm/raspi_platform.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/

#ifndef HW_ARM_RASPI_PLATFORM_H
#define HW_ARM_RASPI_PLATFORM_H

#define MCORE_OFFSET 0x0000 /* Fake frame buffer device
* (the multicore sync block) */
#define IC0_OFFSET 0x2000
Expand Down Expand Up @@ -126,3 +129,5 @@
#define INTERRUPT_VPU1_HALTED 5
#define INTERRUPT_ILLEGAL_TYPE0 6
#define INTERRUPT_ILLEGAL_TYPE1 7

#endif
6 changes: 5 additions & 1 deletion include/hw/kvm/clock.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,11 @@
*
* This work is licensed under the terms of the GNU GPL version 2.
* See the COPYING file in the top-level directory.
*
*/

#ifndef HW_KVM_CLOCK_H
#define HW_KVM_CLOCK_H

#ifdef CONFIG_KVM

void kvmclock_create(void);
Expand All @@ -22,3 +24,5 @@ static inline void kvmclock_create(void)
}

#endif /* !CONFIG_KVM */

#endif
5 changes: 5 additions & 0 deletions include/hw/m68k/mcf_fec.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,12 @@
* (at your option) any later version.
*/

#ifndef HW_M68K_MCF_FEC_H
#define HW_M68K_MCF_FEC_H

#define TYPE_MCF_FEC_NET "mcf-fec"
#define MCF_FEC_NET(obj) OBJECT_CHECK(mcf_fec_state, (obj), TYPE_MCF_FEC_NET)

#define FEC_NUM_IRQ 13

#endif
5 changes: 5 additions & 0 deletions include/hw/mips/bios.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
#ifndef HW_MIPS_BIOS_H
#define HW_MIPS_BIOS_H

#include "qemu/units.h"
#include "cpu.h"

Expand All @@ -7,3 +10,5 @@
#else
#define BIOS_FILENAME "mipsel_bios.bin"
#endif

#endif
5 changes: 5 additions & 0 deletions include/hw/pci-bridge/simba.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@
* THE SOFTWARE.
*/

#ifndef HW_PCI_BRIDGE_SIMBA_H
#define HW_PCI_BRIDGE_SIMBA_H

#include "hw/pci/pci_bridge.h"


Expand All @@ -35,3 +38,5 @@ typedef struct SimbaPCIBridge {
#define TYPE_SIMBA_PCI_BRIDGE "pbm-bridge"
#define SIMBA_PCI_BRIDGE(obj) \
OBJECT_CHECK(SimbaPCIBridge, (obj), TYPE_SIMBA_PCI_BRIDGE)

#endif
5 changes: 5 additions & 0 deletions include/hw/pci/pci_regs.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
#ifndef HW_PCI_PCI_REGS_H
#define HW_PCI_PCI_REGS_H

#include "standard-headers/linux/pci_regs.h"

#define PCI_PM_CAP_VER_1_1 0x0002 /* PCI PM spec ver. 1.1 */

#endif
6 changes: 6 additions & 0 deletions include/hw/qdev-dma.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,11 @@
* This work is licensed under the terms of the GNU GPL, version 2 or later.
* See the COPYING file in the top-level directory.
*/

#ifndef HW_QDEV_DMA_H
#define HW_QDEV_DMA_H

#define DEFINE_PROP_DMAADDR(_n, _s, _f, _d) \
DEFINE_PROP_UINT64(_n, _s, _f, _d)

#endif
4 changes: 4 additions & 0 deletions include/hw/sparc/sparc64.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
#ifndef HW_SPARC_SPARC64_H
#define HW_SPARC_SPARC64_H

#define IVEC_MAX 0x40

SPARCCPU *sparc64_cpu_devinit(const char *cpu_type, uint64_t prom_addr);

void sparc64_cpu_set_ivec_irq(void *opaque, int irq, int level);

#endif
5 changes: 5 additions & 0 deletions include/hw/timer/xlnx-zynqmp-rtc.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@
* THE SOFTWARE.
*/

#ifndef HW_TIMER_XLNX_ZYNQMP_RTC_H
#define HW_TIMER_XLNX_ZYNQMP_RTC_H

#include "hw/register.h"

#define TYPE_XLNX_ZYNQMP_RTC "xlnx-zynmp.rtc"
Expand Down Expand Up @@ -84,3 +87,5 @@ typedef struct XlnxZynqMPRTC {
uint32_t regs[XLNX_ZYNQMP_RTC_R_MAX];
RegisterInfo regs_info[XLNX_ZYNQMP_RTC_R_MAX];
} XlnxZynqMPRTC;

#endif
5 changes: 5 additions & 0 deletions include/ui/spice-display.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@
* along with this program; if not, see <http://www.gnu.org/licenses/>.
*/

#ifndef UI_SPICE_DISPLAY_H
#define UI_SPICE_DISPLAY_H

#include <spice/ipc_ring.h>
#include <spice/enums.h>
#include <spice/qxl_dev.h>
Expand Down Expand Up @@ -183,3 +186,5 @@ int qemu_spice_display_is_running(SimpleSpiceDisplay *ssd);
bool qemu_spice_fill_device_address(QemuConsole *con,
char *device_address,
size_t size);

#endif
4 changes: 4 additions & 0 deletions linux-user/aarch64/syscall_nr.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
* This file contains the system call numbers.
*/

#ifndef LINUX_USER_AARCH64_SYSCALL_NR_H
#define LINUX_USER_AARCH64_SYSCALL_NR_H

#define TARGET_NR_io_setup 0
#define TARGET_NR_io_destroy 1
#define TARGET_NR_io_submit 2
Expand Down Expand Up @@ -274,3 +277,4 @@
#define TARGET_NR_mlock2 284
#define TARGET_NR_copy_file_range 285

#endif
5 changes: 5 additions & 0 deletions linux-user/aarch64/termbits.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
/* from asm/termbits.h */
/* NOTE: exactly the same as i386 */

#ifndef LINUX_USER_AARCH64_TERMBITS_H
#define LINUX_USER_AARCH64_TERMBITS_H

#define TARGET_NCCS 19

struct target_termios {
Expand Down Expand Up @@ -220,3 +223,5 @@ struct target_termios {
#define TARGET_TIOCPKT_DOSTOP 32

#define TARGET_TIOCSER_TEMT 0x01 /* Transmitter physically empty */

#endif
5 changes: 5 additions & 0 deletions linux-user/alpha/syscall_nr.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
#ifndef LINUX_USER_ALPHA_SYSCALL_NR_H
#define LINUX_USER_ALPHA_SYSCALL_NR_H

#define TARGET_NR_osf_syscall 0 /* not implemented */
#define TARGET_NR_exit 1
#define TARGET_NR_fork 2
Expand Down Expand Up @@ -450,3 +453,5 @@
#define TARGET_NR_getrandom 511
#define TARGET_NR_memfd_create 512
#define TARGET_NR_execveat 513

#endif
5 changes: 5 additions & 0 deletions linux-user/alpha/termbits.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
#ifndef LINUX_USER_ALPHA_TERMBITS_H
#define LINUX_USER_ALPHA_TERMBITS_H

typedef unsigned char target_cc_t;
typedef unsigned int target_speed_t;
typedef unsigned int target_tcflag_t;
Expand Down Expand Up @@ -263,3 +266,5 @@ struct target_termios {
#define TARGET_TIOCGICOUNT 0x545D /* read serial port inline interrupt counts */
#define TARGET_TIOCGHAYESESP 0x545E /* Get Hayes ESP configuration */
#define TARGET_TIOCSHAYESESP 0x545F /* Set Hayes ESP configuration */

#endif
5 changes: 5 additions & 0 deletions linux-user/arm/syscall_nr.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
* This file contains the system call numbers.
*/

#ifndef LINUX_USER_ARM_SYSCALL_NR_H
#define LINUX_USER_ARM_SYSCALL_NR_H

#define TARGET_NR_restart_syscall ( 0)
#define TARGET_NR_exit ( 1)
#define TARGET_NR_fork ( 2)
Expand Down Expand Up @@ -396,3 +399,5 @@
#define TARGET_NR_userfaultfd (388)
#define TARGET_NR_membarrier (389)
#define TARGET_NR_mlock2 (390)

#endif
5 changes: 5 additions & 0 deletions linux-user/arm/termbits.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
/* from asm/termbits.h */
/* NOTE: exactly the same as i386 */

#ifndef LINUX_USER_ARM_TERMBITS_H
#define LINUX_USER_ARM_TERMBITS_H

#define TARGET_NCCS 19

struct target_termios {
Expand Down Expand Up @@ -215,3 +218,5 @@ struct target_termios {
#define TARGET_TIOCPKT_DOSTOP 32

#define TARGET_TIOCSER_TEMT 0x01 /* Transmitter physically empty */

#endif
5 changes: 5 additions & 0 deletions linux-user/cris/syscall_nr.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
* This file contains the system call numbers, and stub macros for libc.
*/

#ifndef LINUX_USER_CRIS_SYSCALL_NR_H
#define LINUX_USER_CRIS_SYSCALL_NR_H

#define TARGET_NR_restart_syscall 0
#define TARGET_NR_exit 1
#define TARGET_NR_fork 2
Expand Down Expand Up @@ -360,3 +363,5 @@
#define TARGET_NR_memfd_create 357
#define TARGET_NR_bpf 358
#define TARGET_NR_execveat 359

#endif
Loading

0 comments on commit f91005e

Please sign in to comment.