diff --git a/libmesosphere/include/mesosphere/kern_k_code_memory.hpp b/libmesosphere/include/mesosphere/kern_k_code_memory.hpp index 6f94c8f2..0875216a 100644 --- a/libmesosphere/include/mesosphere/kern_k_code_memory.hpp +++ b/libmesosphere/include/mesosphere/kern_k_code_memory.hpp @@ -23,7 +23,7 @@ namespace ams::kern { class KCodeMemory final : public KAutoObjectWithSlabHeapAndContainer { MESOSPHERE_AUTOOBJECT_TRAITS(KCodeMemory, KAutoObject); private: - TYPED_STORAGE(KPageGroup) m_page_group; + util::TypedStorage m_page_group; KProcess *m_owner; KProcessAddress m_address; KLightLock m_lock; diff --git a/libmesosphere/include/mesosphere/kern_k_transfer_memory.hpp b/libmesosphere/include/mesosphere/kern_k_transfer_memory.hpp index 831b3582..0abb0dbc 100644 --- a/libmesosphere/include/mesosphere/kern_k_transfer_memory.hpp +++ b/libmesosphere/include/mesosphere/kern_k_transfer_memory.hpp @@ -23,7 +23,7 @@ namespace ams::kern { class KTransferMemory final : public KAutoObjectWithSlabHeapAndContainer { MESOSPHERE_AUTOOBJECT_TRAITS(KTransferMemory, KAutoObject); private: - TYPED_STORAGE(KPageGroup) m_page_group; + util::TypedStorage m_page_group; KProcess *m_owner; KProcessAddress m_address; KLightLock m_lock; diff --git a/libstratosphere/include/stratosphere/ddsf/ddsf_device_code_entry.hpp b/libstratosphere/include/stratosphere/ddsf/ddsf_device_code_entry.hpp index 376601bb..2459e394 100644 --- a/libstratosphere/include/stratosphere/ddsf/ddsf_device_code_entry.hpp +++ b/libstratosphere/include/stratosphere/ddsf/ddsf_device_code_entry.hpp @@ -49,7 +49,7 @@ namespace ams::ddsf { NON_MOVEABLE(DeviceCodeEntryHolder); private: util::IntrusiveListNode list_node; - TYPED_STORAGE(DeviceCodeEntry) entry_storage; + util::TypedStorage entry_storage; bool is_constructed; public: using ListTraits = util::IntrusiveListMemberTraitsDeferredAssert<&DeviceCodeEntryHolder::list_node>; diff --git a/libstratosphere/include/stratosphere/ncm/ncm_install_progress.hpp b/libstratosphere/include/stratosphere/ncm/ncm_install_progress.hpp index ba70fe1f..e91309d2 100644 --- a/libstratosphere/include/stratosphere/ncm/ncm_install_progress.hpp +++ b/libstratosphere/include/stratosphere/ncm/ncm_install_progress.hpp @@ -29,7 +29,7 @@ namespace ams::ncm { struct InstallProgress { InstallProgressState state; u8 pad[3]; - TYPED_STORAGE(Result) last_result; + util::TypedStorage last_result; s64 installed_size; s64 total_size; diff --git a/libstratosphere/include/stratosphere/os/impl/os_internal_condition_variable.hpp b/libstratosphere/include/stratosphere/os/impl/os_internal_condition_variable.hpp index 33a34a70..2a48e06b 100644 --- a/libstratosphere/include/stratosphere/os/impl/os_internal_condition_variable.hpp +++ b/libstratosphere/include/stratosphere/os/impl/os_internal_condition_variable.hpp @@ -53,6 +53,6 @@ namespace ams::os::impl { } }; - using InternalConditionVariableStorage = TYPED_STORAGE(InternalConditionVariable); + using InternalConditionVariableStorage = util::TypedStorage; } diff --git a/libstratosphere/include/stratosphere/os/impl/os_internal_critical_section.hpp b/libstratosphere/include/stratosphere/os/impl/os_internal_critical_section.hpp index d1b0871f..ed49fbac 100644 --- a/libstratosphere/include/stratosphere/os/impl/os_internal_critical_section.hpp +++ b/libstratosphere/include/stratosphere/os/impl/os_internal_critical_section.hpp @@ -57,6 +57,6 @@ namespace ams::os::impl { } }; - using InternalCriticalSectionStorage = TYPED_STORAGE(InternalCriticalSection); + using InternalCriticalSectionStorage = util::TypedStorage; } diff --git a/libstratosphere/include/stratosphere/os/os_thread_types.hpp b/libstratosphere/include/stratosphere/os/os_thread_types.hpp index 08f1f632..b0ddb964 100644 --- a/libstratosphere/include/stratosphere/os/os_thread_types.hpp +++ b/libstratosphere/include/stratosphere/os/os_thread_types.hpp @@ -44,7 +44,7 @@ namespace ams::os { State_Terminated = 4, }; - TYPED_STORAGE(util::IntrusiveListNode) all_threads_node; + util::TypedStorage all_threads_node; util::TypedStorage waitlist; uintptr_t reserved[4]; u8 state; diff --git a/libstratosphere/include/stratosphere/os/os_timer_event_types.hpp b/libstratosphere/include/stratosphere/os/os_timer_event_types.hpp index 44e46542..975445d7 100644 --- a/libstratosphere/include/stratosphere/os/os_timer_event_types.hpp +++ b/libstratosphere/include/stratosphere/os/os_timer_event_types.hpp @@ -29,7 +29,7 @@ namespace ams::os { } struct TimerEventType { - using TimeSpanStorage = TYPED_STORAGE(TimeSpan); + using TimeSpanStorage = util::TypedStorage; enum State { State_NotInitialized = 0, diff --git a/libstratosphere/include/stratosphere/powctl/powctl_session_api.hpp b/libstratosphere/include/stratosphere/powctl/powctl_session_api.hpp index 7c0e3fbd..495ad9f0 100644 --- a/libstratosphere/include/stratosphere/powctl/powctl_session_api.hpp +++ b/libstratosphere/include/stratosphere/powctl/powctl_session_api.hpp @@ -35,7 +35,7 @@ namespace ams::powctl { struct Session { bool has_session; - TYPED_STORAGE(impl::SessionImpl) impl_storage; + util::TypedStorage impl_storage; Session() : has_session(false) { /* ... */ } }; diff --git a/libstratosphere/include/stratosphere/sf/cmif/sf_cmif_domain_manager.hpp b/libstratosphere/include/stratosphere/sf/cmif/sf_cmif_domain_manager.hpp index 99b8e201..6f3aea55 100644 --- a/libstratosphere/include/stratosphere/sf/cmif/sf_cmif_domain_manager.hpp +++ b/libstratosphere/include/stratosphere/sf/cmif/sf_cmif_domain_manager.hpp @@ -77,8 +77,8 @@ namespace ams::sf::cmif { virtual ServiceObjectHolder GetObject(DomainObjectId id) override final; }; public: - using DomainEntryStorage = TYPED_STORAGE(Entry); - using DomainStorage = TYPED_STORAGE(Domain); + using DomainEntryStorage = util::TypedStorage; + using DomainStorage = util::TypedStorage; private: class EntryManager { private: diff --git a/libstratosphere/include/stratosphere/sf/hipc/sf_hipc_server_manager.hpp b/libstratosphere/include/stratosphere/sf/hipc/sf_hipc_server_manager.hpp index 19986c90..d611f5d1 100644 --- a/libstratosphere/include/stratosphere/sf/hipc/sf_hipc_server_manager.hpp +++ b/libstratosphere/include/stratosphere/sf/hipc/sf_hipc_server_manager.hpp @@ -260,9 +260,9 @@ namespace ams::sf::hipc { private: /* Resource storage. */ os::Mutex resource_mutex; - TYPED_STORAGE(Server) server_storages[MaxServers]; + util::TypedStorage server_storages[MaxServers]; bool server_allocated[MaxServers]; - TYPED_STORAGE(ServerSession) session_storages[MaxSessions]; + util::TypedStorage session_storages[MaxSessions]; bool session_allocated[MaxSessions]; u8 pointer_buffer_storage[0x10 + (MaxSessions * ManagerOptions::PointerBufferSize)]; u8 saved_message_storage[0x10 + (MaxSessions * hipc::TlsMessageBufferSize)]; diff --git a/libstratosphere/include/stratosphere/sf/impl/sf_impl_command_serialization.hpp b/libstratosphere/include/stratosphere/sf/impl/sf_impl_command_serialization.hpp index 9a0a83e4..f293d15c 100644 --- a/libstratosphere/include/stratosphere/sf/impl/sf_impl_command_serialization.hpp +++ b/libstratosphere/include/stratosphere/sf/impl/sf_impl_command_serialization.hpp @@ -684,7 +684,7 @@ namespace ams::sf::impl { private: std::array in_object_holders; std::array out_object_holders; - std::array), NumOutObjects> out_shared_pointers; + std::array>, NumOutObjects> out_shared_pointers; std::array out_object_ids; public: constexpr InOutObjectHolder() : in_object_holders(), out_object_holders() { diff --git a/libstratosphere/source/fs/fs_code.cpp b/libstratosphere/source/fs/fs_code.cpp index 0fe32294..e58acb3e 100644 --- a/libstratosphere/source/fs/fs_code.cpp +++ b/libstratosphere/source/fs/fs_code.cpp @@ -23,8 +23,8 @@ namespace ams::fs { constinit os::SdkMutex g_mount_stratosphere_romfs_lock; constinit bool g_mounted_stratosphere_romfs = false; - constinit TYPED_STORAGE(FileHandleStorage) g_stratosphere_romfs_storage = {}; - constinit TYPED_STORAGE(RomFsFileSystem) g_stratosphere_romfs_fs = {}; + constinit util::TypedStorage g_stratosphere_romfs_storage = {}; + constinit util::TypedStorage g_stratosphere_romfs_fs = {}; Result EnsureStratosphereRomfsMounted() { std::scoped_lock lk(g_mount_stratosphere_romfs_lock); diff --git a/libstratosphere/source/fssystem/fssystem_file_system_proxy_api.cpp b/libstratosphere/source/fssystem/fssystem_file_system_proxy_api.cpp index 8bc1dd43..fdb76c47 100644 --- a/libstratosphere/source/fssystem/fssystem_file_system_proxy_api.cpp +++ b/libstratosphere/source/fssystem/fssystem_file_system_proxy_api.cpp @@ -68,19 +68,19 @@ namespace ams::fssystem { alignas(os::MemoryPageSize) u8 g_device_buffer[DeviceBufferSize]; alignas(os::MemoryPageSize) u8 g_buffer_pool[BufferPoolSize]; - TYPED_STORAGE(mem::StandardAllocator) g_buffer_allocator; - TYPED_STORAGE(fssrv::MemoryResourceFromStandardAllocator) g_allocator; + util::TypedStorage g_buffer_allocator; + util::TypedStorage g_allocator; /* TODO: Nintendo uses os::SetMemoryHeapSize (svc::SetHeapSize) and os::AllocateMemoryBlock for the BufferManager heap. */ /* It's unclear how we should handle this in ams.mitm (especially hoping to reuse some logic for fs reimpl). */ /* Should we be doing the same(?) */ - TYPED_STORAGE(fssystem::FileSystemBufferManager) g_buffer_manager; + util::TypedStorage g_buffer_manager; alignas(os::MemoryPageSize) u8 g_buffer_manager_heap[BufferManagerHeapSize]; /* FileSystem creators. */ - TYPED_STORAGE(fssrv::fscreator::RomFileSystemCreator) g_rom_fs_creator; - TYPED_STORAGE(fssrv::fscreator::PartitionFileSystemCreator) g_partition_fs_creator; - TYPED_STORAGE(fssrv::fscreator::StorageOnNcaCreator) g_storage_on_nca_creator; + util::TypedStorage g_rom_fs_creator; + util::TypedStorage g_partition_fs_creator; + util::TypedStorage g_storage_on_nca_creator; fssrv::fscreator::FileSystemCreatorInterfaces g_fs_creator_interfaces = {}; diff --git a/libstratosphere/source/htc/server/htc_htcmisc_hipc_server.cpp b/libstratosphere/source/htc/server/htc_htcmisc_hipc_server.cpp index f9ebb2b8..6ee4fda5 100644 --- a/libstratosphere/source/htc/server/htc_htcmisc_hipc_server.cpp +++ b/libstratosphere/source/htc/server/htc_htcmisc_hipc_server.cpp @@ -28,7 +28,7 @@ namespace ams::htc::server { using ServerOptions = sf::hipc::DefaultServerManagerOptions; using ServerManager = sf::hipc::ServerManager; - constinit TYPED_STORAGE(ServerManager) g_server_manager_storage; + constinit util::TypedStorage g_server_manager_storage; constinit ServerManager *g_server_manager = nullptr; constinit HtcmiscImpl *g_misc_impl = nullptr; diff --git a/libstratosphere/source/htcfs/htcfs_client.cpp b/libstratosphere/source/htcfs/htcfs_client.cpp index 27972f26..37a4dc93 100644 --- a/libstratosphere/source/htcfs/htcfs_client.cpp +++ b/libstratosphere/source/htcfs/htcfs_client.cpp @@ -20,7 +20,7 @@ namespace ams::htcfs { namespace { - constinit TYPED_STORAGE(Client) g_client_storage; + constinit util::TypedStorage g_client_storage; constinit bool g_initialized; } diff --git a/libstratosphere/source/htclow/mux/htclow_mux_channel_impl_map.hpp b/libstratosphere/source/htclow/mux/htclow_mux_channel_impl_map.hpp index dee89de1..a5ac0f30 100644 --- a/libstratosphere/source/htclow/mux/htclow_mux_channel_impl_map.hpp +++ b/libstratosphere/source/htclow/mux/htclow_mux_channel_impl_map.hpp @@ -35,7 +35,7 @@ namespace ams::htclow::mux { os::Event *m_event; u8 m_map_buffer[MapRequiredMemorySize]; MapType m_map; - TYPED_STORAGE(ChannelImpl) m_channel_storage[MaxChannelCount]; + util::TypedStorage m_channel_storage[MaxChannelCount]; bool m_storage_valid[MaxChannelCount]; public: ChannelImplMap(PacketFactory *pf, ctrl::HtcctrlStateMachine *sm, TaskManager *tm, os::Event *ev); diff --git a/libstratosphere/source/os/impl/os_resource_manager.cpp b/libstratosphere/source/os/impl/os_resource_manager.cpp index 6ff528a3..4252a7cb 100644 --- a/libstratosphere/source/os/impl/os_resource_manager.cpp +++ b/libstratosphere/source/os/impl/os_resource_manager.cpp @@ -18,6 +18,6 @@ namespace ams::os::impl { - constinit TYPED_STORAGE(OsResourceManager) ResourceManagerHolder::s_resource_manager_storage = {}; + constinit util::TypedStorage ResourceManagerHolder::s_resource_manager_storage = {}; } diff --git a/libstratosphere/source/os/impl/os_resource_manager.hpp b/libstratosphere/source/os/impl/os_resource_manager.hpp index b79babfb..0845ff3f 100644 --- a/libstratosphere/source/os/impl/os_resource_manager.hpp +++ b/libstratosphere/source/os/impl/os_resource_manager.hpp @@ -42,7 +42,7 @@ namespace ams::os::impl { class ResourceManagerHolder { private: - static TYPED_STORAGE(OsResourceManager) s_resource_manager_storage; + static util::TypedStorage s_resource_manager_storage; private: constexpr ResourceManagerHolder() { /* ... */ } public: diff --git a/libstratosphere/source/os/impl/os_waitable_holder_impl.hpp b/libstratosphere/source/os/impl/os_waitable_holder_impl.hpp index 90a3e463..c4798302 100644 --- a/libstratosphere/source/os/impl/os_waitable_holder_impl.hpp +++ b/libstratosphere/source/os/impl/os_waitable_holder_impl.hpp @@ -27,15 +27,15 @@ namespace ams::os::impl { struct WaitableHolderImpl { union { - TYPED_STORAGE(WaitableHolderOfHandle) holder_of_handle_storage; - TYPED_STORAGE(WaitableHolderOfEvent) holder_of_event_storage; - TYPED_STORAGE(WaitableHolderOfInterProcessEvent) holder_of_inter_process_event_storage; - TYPED_STORAGE(WaitableHolderOfInterruptEvent) holder_of_interrupt_event_storage; - TYPED_STORAGE(WaitableHolderOfTimerEvent) holder_of_timer_event_storage; - TYPED_STORAGE(WaitableHolderOfThread) holder_of_thread_storage; - TYPED_STORAGE(WaitableHolderOfSemaphore) holder_of_semaphore_storage; - TYPED_STORAGE(WaitableHolderOfMessageQueueForNotFull) holder_of_mq_for_not_full_storage; - TYPED_STORAGE(WaitableHolderOfMessageQueueForNotEmpty) holder_of_mq_for_not_empty_storage; + util::TypedStorage holder_of_handle_storage; + util::TypedStorage holder_of_event_storage; + util::TypedStorage holder_of_inter_process_event_storage; + util::TypedStorage holder_of_interrupt_event_storage; + util::TypedStorage holder_of_timer_event_storage; + util::TypedStorage holder_of_thread_storage; + util::TypedStorage holder_of_semaphore_storage; + util::TypedStorage holder_of_mq_for_not_full_storage; + util::TypedStorage holder_of_mq_for_not_empty_storage; }; }; diff --git a/libstratosphere/source/pgl/srv/pgl_srv_shell_event_observer.hpp b/libstratosphere/source/pgl/srv/pgl_srv_shell_event_observer.hpp index 7b730589..71e7e653 100644 --- a/libstratosphere/source/pgl/srv/pgl_srv_shell_event_observer.hpp +++ b/libstratosphere/source/pgl/srv/pgl_srv_shell_event_observer.hpp @@ -41,10 +41,10 @@ namespace ams::pgl::srv { os::MessageQueue message_queue; uintptr_t queue_buffer[QueueCapacity]; os::SystemEvent event; - TYPED_STORAGE(lmem::HeapCommonHead) heap_head; + util::TypedStorage heap_head; lmem::HeapHandle heap_handle; pm::ProcessEventInfo event_info_data[QueueCapacity]; - TYPED_STORAGE(ShellEventObserverHolder) holder; + util::TypedStorage holder; public: ShellEventObserver(); ~ShellEventObserver(); diff --git a/libstratosphere/source/sf/hipc/sf_hipc_mitm_query_api.cpp b/libstratosphere/source/sf/hipc/sf_hipc_mitm_query_api.cpp index e5d3f8a6..c641c6b5 100644 --- a/libstratosphere/source/sf/hipc/sf_hipc_mitm_query_api.cpp +++ b/libstratosphere/source/sf/hipc/sf_hipc_mitm_query_api.cpp @@ -50,7 +50,7 @@ namespace ams::sf::hipc::impl { constinit os::ThreadType g_query_server_process_thread; constexpr size_t MaxServers = 0; - TYPED_STORAGE(sf::hipc::ServerManager) g_query_server_storage; + util::TypedStorage> g_query_server_storage; } diff --git a/libvapours/include/vapours/util/util_bounded_map.hpp b/libvapours/include/vapours/util/util_bounded_map.hpp index 41f7593c..5d0ab6ee 100644 --- a/libvapours/include/vapours/util/util_bounded_map.hpp +++ b/libvapours/include/vapours/util/util_bounded_map.hpp @@ -25,7 +25,7 @@ namespace ams::util { class BoundedMap { private: std::array, N> keys; - std::array values; + std::array, N> values; private: ALWAYS_INLINE void FreeEntry(size_t i) { this->keys[i].reset(); diff --git a/libvapours/include/vapours/util/util_intrusive_list.hpp b/libvapours/include/vapours/util/util_intrusive_list.hpp index 737c9586..eefe1b7f 100644 --- a/libvapours/include/vapours/util/util_intrusive_list.hpp +++ b/libvapours/include/vapours/util/util_intrusive_list.hpp @@ -569,7 +569,7 @@ namespace ams::util { return util::GetParentReference(&node); } private: - static constexpr TYPED_STORAGE(Derived) DerivedStorage = {}; + static constexpr TypedStorage DerivedStorage = {}; static_assert(std::addressof(GetParent(GetNode(GetReference(DerivedStorage)))) == GetPointer(DerivedStorage)); }; @@ -582,7 +582,7 @@ namespace ams::util { using ListType = IntrusiveList; static constexpr bool IsValid() { - TYPED_STORAGE(Derived) DerivedStorage = {}; + TypedStorage DerivedStorage = {}; return std::addressof(GetParent(GetNode(GetReference(DerivedStorage)))) == GetPointer(DerivedStorage); } private: diff --git a/libvapours/include/vapours/util/util_intrusive_red_black_tree.hpp b/libvapours/include/vapours/util/util_intrusive_red_black_tree.hpp index 192c8bd7..f43b2fc0 100644 --- a/libvapours/include/vapours/util/util_intrusive_red_black_tree.hpp +++ b/libvapours/include/vapours/util/util_intrusive_red_black_tree.hpp @@ -498,7 +498,7 @@ namespace ams::util { return util::GetParentPointer(node); } private: - static constexpr TYPED_STORAGE(Derived) DerivedStorage = {}; + static constexpr TypedStorage DerivedStorage = {}; static_assert(GetParent(GetNode(GetPointer(DerivedStorage))) == GetPointer(DerivedStorage)); }; @@ -513,7 +513,7 @@ namespace ams::util { using TreeTypeImpl = impl::IntrusiveRedBlackTreeImpl; static constexpr bool IsValid() { - TYPED_STORAGE(Derived) DerivedStorage = {}; + TypedStorage DerivedStorage = {}; return GetParent(GetNode(GetPointer(DerivedStorage))) == GetPointer(DerivedStorage); } private: diff --git a/libvapours/include/vapours/util/util_parent_of_member.hpp b/libvapours/include/vapours/util/util_parent_of_member.hpp index a1600680..19b36478 100644 --- a/libvapours/include/vapours/util/util_parent_of_member.hpp +++ b/libvapours/include/vapours/util/util_parent_of_member.hpp @@ -63,7 +63,7 @@ namespace ams::util { union Union { char c; UnionHolder first_union; - TYPED_STORAGE(ParentType) parent; + TypedStorage parent; /* This coerces the active member to be c. */ constexpr Union() : c() { /* ... */ } @@ -110,7 +110,7 @@ namespace ams::util { template struct OffsetOfCalculator { static constexpr std::ptrdiff_t OffsetOf(MemberType ParentType::*member) { - constexpr TYPED_STORAGE(ParentType) Holder = {}; + constexpr TypedStorage Holder = {}; const auto *parent = GetPointer(Holder); const auto *target = std::addressof(parent->*member); return static_cast(static_cast(target)) - static_cast(static_cast(parent)); diff --git a/libvapours/include/vapours/util/util_typed_storage.hpp b/libvapours/include/vapours/util/util_typed_storage.hpp index de1db3f8..cfbb9505 100644 --- a/libvapours/include/vapours/util/util_typed_storage.hpp +++ b/libvapours/include/vapours/util/util_typed_storage.hpp @@ -20,30 +20,28 @@ namespace ams::util { - template + template struct TypedStorage { typename std::aligned_storage::type _storage; }; - #define TYPED_STORAGE(...) ::ams::util::TypedStorage<__VA_ARGS__, sizeof(__VA_ARGS__), alignof(__VA_ARGS__)> - template - static constexpr ALWAYS_INLINE T *GetPointer(TYPED_STORAGE(T) &ts) { + static constexpr ALWAYS_INLINE T *GetPointer(TypedStorage &ts) { return static_cast(static_cast(std::addressof(ts._storage))); } template - static constexpr ALWAYS_INLINE const T *GetPointer(const TYPED_STORAGE(T) &ts) { + static constexpr ALWAYS_INLINE const T *GetPointer(const TypedStorage &ts) { return static_cast(static_cast(std::addressof(ts._storage))); } template - static constexpr ALWAYS_INLINE T &GetReference(TYPED_STORAGE(T) &ts) { + static constexpr ALWAYS_INLINE T &GetReference(TypedStorage &ts) { return *GetPointer(ts); } template - static constexpr ALWAYS_INLINE const T &GetReference(const TYPED_STORAGE(T) &ts) { + static constexpr ALWAYS_INLINE const T &GetReference(const TypedStorage &ts) { return *GetPointer(ts); } diff --git a/libvapours/source/sdmmc/impl/sdmmc_sdmmc_controller.board.nintendo_nx.hpp b/libvapours/source/sdmmc/impl/sdmmc_sdmmc_controller.board.nintendo_nx.hpp index d007d9dd..d731842f 100644 --- a/libvapours/source/sdmmc/impl/sdmmc_sdmmc_controller.board.nintendo_nx.hpp +++ b/libvapours/source/sdmmc/impl/sdmmc_sdmmc_controller.board.nintendo_nx.hpp @@ -237,7 +237,7 @@ namespace ams::sdmmc::impl { #if defined(AMS_SDMMC_USE_PCV_CLOCK_RESET_CONTROL) bool is_pcv_control; #endif - TYPED_STORAGE(PowerController) power_controller_storage; + util::TypedStorage power_controller_storage; PowerController *power_controller; private: Result PowerOnForRegisterControl(BusPower bus_power);