From 5802a362f83bba3959a260ea9e00e4c65cf9508f Mon Sep 17 00:00:00 2001 From: Lane Kolbly Date: Tue, 7 Apr 2020 15:19:32 -0500 Subject: uhd: Replace include guards with pragma once Pragma once is the more modern version of include guards, eliminating any potential problems with mistyping include guards. Let's use those. --- host/lib/include/uhdlib/usrp/common/ad9361_ctrl.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/ad936x_manager.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/adf4001_ctrl.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/adf435x.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/adf535x.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/apply_corrections.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/async_packet_handler.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/dpdk_io_service_mgr.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/fx2_ctrl.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/io_service_args.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/io_service_mgr.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/lmx2592.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/mpmd_mb_controller.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/recv_packet_demuxer.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/recv_packet_demuxer_3000.hpp | 5 +---- host/lib/include/uhdlib/usrp/common/validate_subdev_spec.hpp | 5 +---- 16 files changed, 16 insertions(+), 64 deletions(-) (limited to 'host/lib/include/uhdlib/usrp/common') diff --git a/host/lib/include/uhdlib/usrp/common/ad9361_ctrl.hpp b/host/lib/include/uhdlib/usrp/common/ad9361_ctrl.hpp index c059a3a09..6fa9d0e74 100644 --- a/host/lib/include/uhdlib/usrp/common/ad9361_ctrl.hpp +++ b/host/lib/include/uhdlib/usrp/common/ad9361_ctrl.hpp @@ -5,8 +5,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_AD9361_CTRL_HPP -#define INCLUDED_AD9361_CTRL_HPP +#pragma once #include #include @@ -162,5 +161,3 @@ public: }; }} // namespace uhd::usrp - -#endif /* INCLUDED_AD9361_CTRL_HPP */ diff --git a/host/lib/include/uhdlib/usrp/common/ad936x_manager.hpp b/host/lib/include/uhdlib/usrp/common/ad936x_manager.hpp index d65983c72..61b792a1b 100644 --- a/host/lib/include/uhdlib/usrp/common/ad936x_manager.hpp +++ b/host/lib/include/uhdlib/usrp/common/ad936x_manager.hpp @@ -5,8 +5,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_AD9361_MANAGER_HPP -#define INCLUDED_AD9361_MANAGER_HPP +#pragma once #include #include @@ -110,5 +109,3 @@ public: }; /* class ad936x_manager */ }} /* namespace uhd::usrp */ - -#endif /* INCLUDED_AD9361_MANAGER_HPP */ diff --git a/host/lib/include/uhdlib/usrp/common/adf4001_ctrl.hpp b/host/lib/include/uhdlib/usrp/common/adf4001_ctrl.hpp index 0c1b06458..a98238a25 100644 --- a/host/lib/include/uhdlib/usrp/common/adf4001_ctrl.hpp +++ b/host/lib/include/uhdlib/usrp/common/adf4001_ctrl.hpp @@ -10,8 +10,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_LIBUHD_USRP_COMMON_ADF4001_HPP -#define INCLUDED_LIBUHD_USRP_COMMON_ADF4001_HPP +#pragma once #include #include @@ -119,5 +118,3 @@ private: }; }} // namespace uhd::usrp - -#endif diff --git a/host/lib/include/uhdlib/usrp/common/adf435x.hpp b/host/lib/include/uhdlib/usrp/common/adf435x.hpp index e805f9754..de93bfd69 100644 --- a/host/lib/include/uhdlib/usrp/common/adf435x.hpp +++ b/host/lib/include/uhdlib/usrp/common/adf435x.hpp @@ -6,8 +6,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_ADF435X_HPP -#define INCLUDED_ADF435X_HPP +#pragma once #include "adf4350_regs.hpp" #include "adf4351_regs.hpp" @@ -615,5 +614,3 @@ inline int adf435x_impl::_get_rfdiv_setting(uint16_t div) UHD_THROW_INVALID_CODE_PATH(); } } - -#endif // INCLUDED_ADF435X_HPP diff --git a/host/lib/include/uhdlib/usrp/common/adf535x.hpp b/host/lib/include/uhdlib/usrp/common/adf535x.hpp index 65e552844..e8f4a9309 100644 --- a/host/lib/include/uhdlib/usrp/common/adf535x.hpp +++ b/host/lib/include/uhdlib/usrp/common/adf535x.hpp @@ -5,8 +5,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_ADF535X_HPP -#define INCLUDED_ADF535X_HPP +#pragma once #include "adf5355_regs.hpp" #include "adf5356_regs.hpp" @@ -614,5 +613,3 @@ inline void adf535x_impl::_commit() _write_fn(addr_vtr_t(ONE_REG, _regs.get_reg(0))); } } - -#endif // INCLUDED_ADF535X_HPP diff --git a/host/lib/include/uhdlib/usrp/common/apply_corrections.hpp b/host/lib/include/uhdlib/usrp/common/apply_corrections.hpp index fb9aaa8f1..66a103456 100644 --- a/host/lib/include/uhdlib/usrp/common/apply_corrections.hpp +++ b/host/lib/include/uhdlib/usrp/common/apply_corrections.hpp @@ -5,8 +5,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_LIBUHD_USRP_COMMON_APPLY_CORRECTIONS_HPP -#define INCLUDED_LIBUHD_USRP_COMMON_APPLY_CORRECTIONS_HPP +#pragma once #include #include @@ -76,5 +75,3 @@ void apply_rx_fe_corrections(property_tree::sptr sub_tree, // starts at mboards/ }} // namespace uhd::usrp - -#endif /* INCLUDED_LIBUHD_USRP_COMMON_APPLY_CORRECTIONS_HPP */ diff --git a/host/lib/include/uhdlib/usrp/common/async_packet_handler.hpp b/host/lib/include/uhdlib/usrp/common/async_packet_handler.hpp index 957afe7c1..6b61b5674 100644 --- a/host/lib/include/uhdlib/usrp/common/async_packet_handler.hpp +++ b/host/lib/include/uhdlib/usrp/common/async_packet_handler.hpp @@ -5,8 +5,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_LIBUHD_USRP_COMMON_ASYNC_PACKET_HANDLER_HPP -#define INCLUDED_LIBUHD_USRP_COMMON_ASYNC_PACKET_HANDLER_HPP +#pragma once #include #include @@ -61,5 +60,3 @@ UHD_INLINE void standard_async_msg_prints(const async_metadata_t& metadata) }} // namespace uhd::usrp - -#endif /* INCLUDED_LIBUHD_USRP_COMMON_ASYNC_PACKET_HANDLER_HPP */ diff --git a/host/lib/include/uhdlib/usrp/common/dpdk_io_service_mgr.hpp b/host/lib/include/uhdlib/usrp/common/dpdk_io_service_mgr.hpp index 018f78f38..77ed648c3 100644 --- a/host/lib/include/uhdlib/usrp/common/dpdk_io_service_mgr.hpp +++ b/host/lib/include/uhdlib/usrp/common/dpdk_io_service_mgr.hpp @@ -4,8 +4,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_UHDLIB_TRANSPORT_DPDK_IO_SERVICE_MGR_HPP -#define INCLUDED_UHDLIB_TRANSPORT_DPDK_IO_SERVICE_MGR_HPP +#pragma once #include #include @@ -65,5 +64,3 @@ private: }; }} // namespace uhd::usrp - -#endif /* INCLUDED_UHDLIB_TRANSPORT_DPDK_IO_SERVICE_MGR_HPP */ diff --git a/host/lib/include/uhdlib/usrp/common/fx2_ctrl.hpp b/host/lib/include/uhdlib/usrp/common/fx2_ctrl.hpp index 23498c96e..39a7a6fa4 100644 --- a/host/lib/include/uhdlib/usrp/common/fx2_ctrl.hpp +++ b/host/lib/include/uhdlib/usrp/common/fx2_ctrl.hpp @@ -5,8 +5,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_LIBUHD_USRP_COMMON_FX2_CTRL_HPP -#define INCLUDED_LIBUHD_USRP_COMMON_FX2_CTRL_HPP +#pragma once #include #include //i2c iface @@ -130,5 +129,3 @@ public: }; }} // namespace uhd::usrp - -#endif /* INCLUDED_LIBUHD_USRP_COMMON_FX2_CTRL_HPP */ diff --git a/host/lib/include/uhdlib/usrp/common/io_service_args.hpp b/host/lib/include/uhdlib/usrp/common/io_service_args.hpp index e294df8ee..779b3faae 100644 --- a/host/lib/include/uhdlib/usrp/common/io_service_args.hpp +++ b/host/lib/include/uhdlib/usrp/common/io_service_args.hpp @@ -4,8 +4,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_LIBUHD_IO_SERVICE_ARGS_HPP -#define INCLUDED_LIBUHD_IO_SERVICE_ARGS_HPP +#pragma once #include #include @@ -99,5 +98,3 @@ device_addr_t merge_io_service_dev_args( const device_addr_t& dev_args, const device_addr_t& stream_args); }} // namespace uhd::usrp - -#endif /* INCLUDED_LIBUHD_IO_SERVICE_ARGS_HPP */ diff --git a/host/lib/include/uhdlib/usrp/common/io_service_mgr.hpp b/host/lib/include/uhdlib/usrp/common/io_service_mgr.hpp index 2707c564c..6b2662703 100644 --- a/host/lib/include/uhdlib/usrp/common/io_service_mgr.hpp +++ b/host/lib/include/uhdlib/usrp/common/io_service_mgr.hpp @@ -4,8 +4,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_LIBUHD_IO_SERVICE_MGR_HPP -#define INCLUDED_LIBUHD_IO_SERVICE_MGR_HPP +#pragma once #include #include @@ -102,5 +101,3 @@ public: }; }} // namespace uhd::usrp - -#endif /* INCLUDED_LIBUHD_IO_SERVICE_MGR_HPP */ diff --git a/host/lib/include/uhdlib/usrp/common/lmx2592.hpp b/host/lib/include/uhdlib/usrp/common/lmx2592.hpp index 74a4df437..ad24689d4 100644 --- a/host/lib/include/uhdlib/usrp/common/lmx2592.hpp +++ b/host/lib/include/uhdlib/usrp/common/lmx2592.hpp @@ -4,8 +4,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_LMX2592_HPP -#define INCLUDED_LMX2592_HPP +#pragma once #include "lmx2592_regs.hpp" #include @@ -53,5 +52,3 @@ public: virtual void commit() = 0; }; - -#endif // INCLUDED_LMX2592_HPP diff --git a/host/lib/include/uhdlib/usrp/common/mpmd_mb_controller.hpp b/host/lib/include/uhdlib/usrp/common/mpmd_mb_controller.hpp index 25d32ee28..7285eb254 100644 --- a/host/lib/include/uhdlib/usrp/common/mpmd_mb_controller.hpp +++ b/host/lib/include/uhdlib/usrp/common/mpmd_mb_controller.hpp @@ -4,8 +4,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_LIBUHD_MPMD_MB_CONTROLLER_HPP -#define INCLUDED_LIBUHD_MPMD_MB_CONTROLLER_HPP +#pragma once #include #include @@ -108,5 +107,3 @@ private: }; }} // namespace uhd::rfnoc - -#endif /* INCLUDED_LIBUHD_MPMD_MB_CONTROLLER_HPP */ diff --git a/host/lib/include/uhdlib/usrp/common/recv_packet_demuxer.hpp b/host/lib/include/uhdlib/usrp/common/recv_packet_demuxer.hpp index 09882378e..79c093314 100644 --- a/host/lib/include/uhdlib/usrp/common/recv_packet_demuxer.hpp +++ b/host/lib/include/uhdlib/usrp/common/recv_packet_demuxer.hpp @@ -5,8 +5,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_LIBUHD_USRP_COMMON_RECV_PACKET_DEMUXER_HPP -#define INCLUDED_LIBUHD_USRP_COMMON_RECV_PACKET_DEMUXER_HPP +#pragma once #include #include @@ -33,5 +32,3 @@ public: }; }} // namespace uhd::usrp - -#endif /* INCLUDED_LIBUHD_USRP_COMMON_RECV_PACKET_DEMUXER_HPP */ diff --git a/host/lib/include/uhdlib/usrp/common/recv_packet_demuxer_3000.hpp b/host/lib/include/uhdlib/usrp/common/recv_packet_demuxer_3000.hpp index 4d20e17cc..9cbede8e4 100644 --- a/host/lib/include/uhdlib/usrp/common/recv_packet_demuxer_3000.hpp +++ b/host/lib/include/uhdlib/usrp/common/recv_packet_demuxer_3000.hpp @@ -5,8 +5,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_LIBUHD_USRP_COMMON_RECV_PACKET_DEMUXER_3000_HPP -#define INCLUDED_LIBUHD_USRP_COMMON_RECV_PACKET_DEMUXER_3000_HPP +#pragma once #include #include @@ -161,5 +160,3 @@ inline transport::zero_copy_if::sptr recv_packet_demuxer_3000::make_proxy( } }} // namespace uhd::usrp - -#endif /* INCLUDED_LIBUHD_USRP_COMMON_RECV_PACKET_DEMUXER_3000_HPP */ diff --git a/host/lib/include/uhdlib/usrp/common/validate_subdev_spec.hpp b/host/lib/include/uhdlib/usrp/common/validate_subdev_spec.hpp index eb56da12e..2ab996cfd 100644 --- a/host/lib/include/uhdlib/usrp/common/validate_subdev_spec.hpp +++ b/host/lib/include/uhdlib/usrp/common/validate_subdev_spec.hpp @@ -5,8 +5,7 @@ // SPDX-License-Identifier: GPL-3.0-or-later // -#ifndef INCLUDED_LIBUHD_USRP_COMMON_VALIDATE_SUBDEV_SPEC_HPP -#define INCLUDED_LIBUHD_USRP_COMMON_VALIDATE_SUBDEV_SPEC_HPP +#pragma once #include #include @@ -22,5 +21,3 @@ void validate_subdev_spec(property_tree::sptr tree, const std::string& mb = "0"); }} // namespace uhd::usrp - -#endif /* INCLUDED_LIBUHD_USRP_COMMON_VALIDATE_SUBDEV_SPEC_HPP */ -- cgit v1.2.3