From be044e691c10400c9b713bc75f7c032375769523 Mon Sep 17 00:00:00 2001 From: Michael Scire Date: Tue, 30 Oct 2018 15:57:15 -0700 Subject: [PATCH] libstrat: delete old ipc templating. --- .../stratosphere/ipc/ipc_templating_old.hpp | 569 ------------------ 1 file changed, 569 deletions(-) delete mode 100644 stratosphere/libstratosphere/include/stratosphere/ipc/ipc_templating_old.hpp diff --git a/stratosphere/libstratosphere/include/stratosphere/ipc/ipc_templating_old.hpp b/stratosphere/libstratosphere/include/stratosphere/ipc/ipc_templating_old.hpp deleted file mode 100644 index 3b9c4960d..000000000 --- a/stratosphere/libstratosphere/include/stratosphere/ipc/ipc_templating_old.hpp +++ /dev/null @@ -1,569 +0,0 @@ -/* - * Copyright (c) 2018 Atmosphère-NX - * - * This program is free software; you can redistribute it and/or modify it - * under the terms and conditions of the GNU General Public License, - * version 2, as published by the Free Software Foundation. - * - * This program is distributed in the hope it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for - * more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -#pragma once -#include -#include -#include -#include -#include -#include - -#include "domainowner.hpp" - -#pragma GCC diagnostic push -#pragma GCC diagnostic ignored "-Wunused-but-set-variable" - -/* Base for In/Out Buffers. */ -struct IpcBufferBase {}; - -/* Represents an A descriptor. */ -struct InBufferBase : IpcBufferBase {}; - -template -struct InBuffer : InBufferBase { - T *buffer; - size_t num_elements; - BufferType type; - static const BufferType expected_type = e_t; - - InBuffer(void *b, size_t n, BufferType t) : buffer((T *)b), num_elements(n/sizeof(T)), type(t) { } -}; - -/* Represents a B descriptor. */ -struct OutBufferBase : IpcBufferBase {}; - -template -struct OutBuffer : OutBufferBase { - T *buffer; - size_t num_elements; - BufferType type; - static const BufferType expected_type = e_t; - - OutBuffer(void *b, size_t n, BufferType t) : buffer((T *)b), num_elements(n/sizeof(T)), type(t) { } -}; - -/* Represents an X descriptor. */ -template -struct InPointer : IpcBufferBase { - T *pointer; - size_t num_elements; - - InPointer(void *p, size_t n) : pointer((T *)p), num_elements(n/sizeof(T)) { } -}; - -/* Represents a C descriptor. */ -struct OutPointerWithServerSizeBase : IpcBufferBase {}; - -template -struct OutPointerWithServerSize : OutPointerWithServerSizeBase { - T *pointer; - static const size_t num_elements = n; - - OutPointerWithServerSize(void *p) : pointer((T *)p) { } -}; - -/* Represents a C descriptor with size in raw data. */ -template -struct OutPointerWithClientSize : IpcBufferBase { - T *pointer; - size_t num_elements; - - OutPointerWithClientSize(void *p, size_t n) : pointer((T *)p), num_elements(n/sizeof(T)) { } -}; - -/* Represents an input PID. */ -struct PidDescriptor { - u64 pid; - - PidDescriptor(u64 p) : pid(p) { } -}; - -/* Represents a moved handle. */ -struct MovedHandle { - Handle handle; - - MovedHandle(Handle h) : handle(h) { } -}; - -/* Represents a copied handle. */ -struct CopiedHandle { - Handle handle; - - CopiedHandle(Handle h) : handle(h) { } -}; - -/* Forward declarations. */ -template -class ISession; - -/* Represents an output ServiceObject. */ -struct OutSessionBase {}; - -template -struct OutSession : OutSessionBase { - ISession *session; - u32 domain_id; - - OutSession(ISession *s) : session(s), domain_id(DOMAIN_ID_MAX) { } -}; - -/* Utilities. */ -template class Template> -struct is_specialization_of { - static const bool value = false; -}; - -template