From patchwork Mon Nov 27 10:24:52 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469313 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6AB51C4167B for ; Mon, 27 Nov 2023 10:26:02 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641719.1000507 (Exim 4.92) (envelope-from ) id 1r7Yo6-0000EM-U5; Mon, 27 Nov 2023 10:25:38 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641719.1000507; Mon, 27 Nov 2023 10:25:38 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yo6-0000De-Qp; Mon, 27 Nov 2023 10:25:38 +0000 Received: by outflank-mailman (input) for mailman id 641719; Mon, 27 Nov 2023 10:25:37 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yo5-0000Co-Ja for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:25:37 +0000 Received: from smtp-out2.suse.de (smtp-out2.suse.de [2a07:de40:b251:101:10:150:64:2]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 4c37c0a3-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:25:35 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 23457202A5; Mon, 27 Nov 2023 10:25:31 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id EDAFA132A6; Mon, 27 Nov 2023 10:25:30 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id O/zJOJpuZGV+fgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:25:30 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 4c37c0a3-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 01/32] Mini-OS: link kernel separately Date: Mon, 27 Nov 2023 11:24:52 +0100 Message-Id: <20231127102523.28003-2-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: ++++++++++++++++++ X-Rspamd-Server: rspamd1 X-Rspamd-Queue-Id: 23457202A5 Authentication-Results: smtp-out2.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out2.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Spamd-Result: default: False [18.90 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_FAIL(1.00)[-all]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; BROKEN_CONTENT_TYPE(1.50)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; RCPT_COUNT_FIVE(0.00)[5]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; BAYES_SPAM(5.10)[100.00%]; MX_GOOD(-0.01)[]; NEURAL_HAM_SHORT(-0.20)[-1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email,ens-lyon.org:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add an additional link step with linking all Mini-OS kernel binaries into a single object file. This is done in preparation of hiding Mini-OS internal symbols before linking the kernel with libraries and an application. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- Makefile | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 7ee181a2..85c6db75 100644 --- a/Makefile +++ b/Makefile @@ -164,8 +164,11 @@ endif $(OBJ_DIR)/arch/x86/minios-x86%.lds: arch/x86/minios-x86.lds.S $(CPP) $(ASFLAGS) -P $< -o $@ -$(OBJ_DIR)/$(TARGET): $(OBJS) $(APP_O) arch_lib $(OBJ_DIR)/$(TARGET_ARCH_DIR)/minios-$(MINIOS_TARGET_ARCH).lds - $(LD) -r $(LDFLAGS) $(HEAD_OBJ) $(APP_O) $(OBJS) $(LDARCHLIB) $(LDLIBS) -o $@.o +$(OBJ_DIR)/$(TARGET)-kern.o: $(OBJS) arch_lib $(OBJ_DIR)/$(TARGET_ARCH_DIR)/minios-$(MINIOS_TARGET_ARCH).lds + $(LD) -r $(LDFLAGS) $(HEAD_OBJ) $(OBJS) $(LDARCHLIB) -o $@ + +$(OBJ_DIR)/$(TARGET): $(OBJ_DIR)/$(TARGET)-kern.o $(APP_O) + $(LD) -r $(LDFLAGS) $(OBJ_DIR)/$(TARGET)-kern.o $(APP_O) $(LDLIBS) -o $@.o $(OBJCOPY) -w -G $(GLOBAL_PREFIX)* -G _start $@.o $@.o $(LD) $(LDFLAGS) $(LDFLAGS_FINAL) $@.o $(EXTRA_OBJS) -o $@-debug strip -s $@-debug -o $@ From patchwork Mon Nov 27 10:24:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469310 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 9BE45C4167B for ; Mon, 27 Nov 2023 10:25:53 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641720.1000516 (Exim 4.92) (envelope-from ) id 1r7Yo8-0000WN-3r; Mon, 27 Nov 2023 10:25:40 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641720.1000516; Mon, 27 Nov 2023 10:25:40 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yo8-0000WG-1E; Mon, 27 Nov 2023 10:25:40 +0000 Received: by outflank-mailman (input) for mailman id 641720; Mon, 27 Nov 2023 10:25:39 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yo6-0000Co-VX for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:25:39 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 4ea601b5-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:25:38 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id A651121B08; Mon, 27 Nov 2023 10:25:36 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 7BEF0132A6; Mon, 27 Nov 2023 10:25:36 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id LxsHHaBuZGWJfgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:25:36 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 4ea601b5-8d0f-11ee-98e2-6d05b1d4d9a1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080736; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=PJU+VtDFhLX4cjANmjzlM4a1Q5rxASlVJ6nflK0YN+k=; b=j1vwIKyjbJyvqjZ1t4HjsJ+Y4aFWtuR+uZAUGsRof411x235iZX+VltoGc9Yt6/58fc0IK IA6RNDtFW6+LWlI/jxYTdRRRH4T5TSigWnGRRKFkau9gwY7fv7NhMLkYyQUlXtxotTXHSu TBVslUVKLc6cBgShiznv2EcZYduj/uI= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 02/32] Mini-OS: explicitly mark symbols to be visible for apps Date: Mon, 27 Nov 2023 11:24:53 +0100 Message-Id: <20231127102523.28003-3-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out1.suse.de; none X-Spamd-Result: default: False [16.50 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(5.10)[100.00%]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_SHORT(3.00)[1.000]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email,minios-config.mk:url]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add an EXPORT_SYMBOL() macro to explicitly mark a symbol to be visible for an app or library linked with Mini-OS. This prepares hiding all other symbols from external components, avoiding any problems with duplicate symbol names. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- .gitignore | 1 + Makefile | 3 ++- include/export.h | 10 ++++++++++ include/lib.h | 1 + 4 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 include/export.h diff --git a/.gitignore b/.gitignore index abef46b2..bacf787e 100644 --- a/.gitignore +++ b/.gitignore @@ -16,3 +16,4 @@ mini-os.gz minios-config.mk mini-os-debug mini-os-debug.gz +syms diff --git a/Makefile b/Makefile index 85c6db75..588496cb 100644 --- a/Makefile +++ b/Makefile @@ -166,10 +166,11 @@ $(OBJ_DIR)/arch/x86/minios-x86%.lds: arch/x86/minios-x86.lds.S $(OBJ_DIR)/$(TARGET)-kern.o: $(OBJS) arch_lib $(OBJ_DIR)/$(TARGET_ARCH_DIR)/minios-$(MINIOS_TARGET_ARCH).lds $(LD) -r $(LDFLAGS) $(HEAD_OBJ) $(OBJS) $(LDARCHLIB) -o $@ + $(OBJCOPY) --dump-section .export_symbol=$(OBJ_DIR)/syms $@ $(OBJ_DIR)/$(TARGET): $(OBJ_DIR)/$(TARGET)-kern.o $(APP_O) $(LD) -r $(LDFLAGS) $(OBJ_DIR)/$(TARGET)-kern.o $(APP_O) $(LDLIBS) -o $@.o - $(OBJCOPY) -w -G $(GLOBAL_PREFIX)* -G _start $@.o $@.o + $(OBJCOPY) -w -G $(GLOBAL_PREFIX)* -G _start --remove-section=.export_symbol $@.o $@.o $(LD) $(LDFLAGS) $(LDFLAGS_FINAL) $@.o $(EXTRA_OBJS) -o $@-debug strip -s $@-debug -o $@ gzip -n -f -9 -c $@-debug >$@-debug.gz diff --git a/include/export.h b/include/export.h new file mode 100644 index 00000000..7140ac68 --- /dev/null +++ b/include/export.h @@ -0,0 +1,10 @@ +#ifndef _EXPORT_H_ +#define _EXPORT_H_ + +/* Mark a symbol to be visible for apps and libs. */ +#define EXPORT_SYMBOL(sym) \ + asm(".section .export_symbol\n" \ + ".ascii \""#sym"\\n\"\n" \ + ".previous\n") + +#endif /* _EXPORT_H_ */ diff --git a/include/lib.h b/include/lib.h index dd68985a..abd4e9ab 100644 --- a/include/lib.h +++ b/include/lib.h @@ -53,6 +53,7 @@ #include #include #include +#include #include "gntmap.h" #if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6) From patchwork Mon Nov 27 10:24:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469314 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6B5B5C4167B for ; Mon, 27 Nov 2023 10:26:05 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641722.1000531 (Exim 4.92) (envelope-from ) id 1r7YoF-0000y0-DH; Mon, 27 Nov 2023 10:25:47 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641722.1000531; Mon, 27 Nov 2023 10:25:47 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YoF-0000xt-9x; Mon, 27 Nov 2023 10:25:47 +0000 Received: by outflank-mailman (input) for mailman id 641722; Mon, 27 Nov 2023 10:25:45 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YoD-0008NG-Dc for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:25:45 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [2a07:de40:b251:101:10:150:64:1]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 5169d7ec-8d0f-11ee-9b0e-b553b5be7939; Mon, 27 Nov 2023 11:25:42 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 31D6C21B08; Mon, 27 Nov 2023 10:25:42 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 09058132A6; Mon, 27 Nov 2023 10:25:42 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id Oaj9AKZuZGWLfgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:25:42 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 5169d7ec-8d0f-11ee-9b0e-b553b5be7939 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 03/32] Mini-OS: add EXPORT_SYMBOL() instances to kernel.c Date: Mon, 27 Nov 2023 11:24:54 +0100 Message-Id: <20231127102523.28003-4-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: +++++++++++++++++++++ Authentication-Results: smtp-out1.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out1.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Rspamd-Server: rspamd2 X-Spamd-Result: default: False [21.50 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_FAIL(1.00)[-all]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; BROKEN_CONTENT_TYPE(1.50)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; BAYES_SPAM(0.00)[16.52%]; NEURAL_SPAM_SHORT(3.00)[1.000]; MX_GOOD(-0.01)[]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] X-Rspamd-Queue-Id: 31D6C21B08 Add the needed instances of EXPORT_SYMBOL() to kernel.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- kernel.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/kernel.c b/kernel.c index 1f97d8dd..0b444940 100644 --- a/kernel.c +++ b/kernel.c @@ -50,6 +50,9 @@ #include #include +void _start(void); +EXPORT_SYMBOL(_start); + uint8_t xen_features[XENFEAT_NR_SUBMAPS * 32]; char cmdline[MAX_CMDLINE_SIZE]; @@ -181,6 +184,7 @@ void stop_kernel(void) /* Reset arch details */ arch_fini(); } +EXPORT_SYMBOL(stop_kernel); /* * do_exit: This is called whenever an IRET fails in entry.S. @@ -199,3 +203,4 @@ void do_exit(void) HYPERVISOR_sched_op(SCHEDOP_shutdown, &sched_shutdown); } } +EXPORT_SYMBOL(do_exit); From patchwork Mon Nov 27 10:24:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469312 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CB568C4167B for ; Mon, 27 Nov 2023 10:25:59 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641725.1000549 (Exim 4.92) (envelope-from ) id 1r7YoI-0001Nm-QH; Mon, 27 Nov 2023 10:25:50 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641725.1000549; Mon, 27 Nov 2023 10:25:50 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YoI-0001NY-N4; Mon, 27 Nov 2023 10:25:50 +0000 Received: by outflank-mailman (input) for mailman id 641725; Mon, 27 Nov 2023 10:25:49 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YoH-0000Co-Is for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:25:49 +0000 Received: from smtp-out2.suse.de (smtp-out2.suse.de [2a07:de40:b251:101:10:150:64:2]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 549a28c2-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:25:48 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id ADE80202A8; Mon, 27 Nov 2023 10:25:47 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 84D56132A6; Mon, 27 Nov 2023 10:25:47 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id JY4dH6tuZGWTfgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:25:47 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 549a28c2-8d0f-11ee-98e2-6d05b1d4d9a1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080747; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=YtTXnS8twSeqnIiZ7AYCOkSOLGbyxVJLKTGBp2+gyoo=; b=QfuLCQS3JRkaG0G9i4/hjoQ9rA6p1pohqz+leGCYPJxjnqn2B5/RTbzr0qJoc2AEYpYNCr 5SVTeMcI0iSD+YC2DqZfsiGOMYAi1Gxt6TacmfESNYTbaoiWmebJ0M8ywih0CuMCocBc47 LtZQpC73wmeE+H7WmUPxol4h5BfYBFc= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 04/32] Mini-OS: add EXPORT_SYMBOL() instances to hypervisor.c Date: Mon, 27 Nov 2023 11:24:55 +0100 Message-Id: <20231127102523.28003-5-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out2.suse.de; none X-Spamd-Result: default: False [3.70 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_HAM_SHORT(-0.20)[-0.999]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to hypervisor.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- hypervisor.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/hypervisor.c b/hypervisor.c index d3857e70..f2cbbc1c 100644 --- a/hypervisor.c +++ b/hypervisor.c @@ -31,6 +31,8 @@ #include #include +EXPORT_SYMBOL(hypercall_page); + #define active_evtchns(cpu,sh,idx) \ ((sh)->evtchn_pending[idx] & \ ~(sh)->evtchn_mask[idx]) @@ -157,6 +159,7 @@ inline void mask_evtchn(uint32_t port) shared_info_t *s = HYPERVISOR_shared_info; synch_set_bit(port, &s->evtchn_mask[0]); } +EXPORT_SYMBOL(mask_evtchn); inline void unmask_evtchn(uint32_t port) { @@ -180,9 +183,11 @@ inline void unmask_evtchn(uint32_t port) force_evtchn_callback(); } } +EXPORT_SYMBOL(unmask_evtchn); inline void clear_evtchn(uint32_t port) { shared_info_t *s = HYPERVISOR_shared_info; synch_clear_bit(port, &s->evtchn_pending[0]); } +EXPORT_SYMBOL(clear_evtchn); From patchwork Mon Nov 27 10:24:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469315 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id E32A5C4167B for ; Mon, 27 Nov 2023 10:26:09 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641730.1000559 (Exim 4.92) (envelope-from ) id 1r7YoN-0001rI-3s; Mon, 27 Nov 2023 10:25:55 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641730.1000559; Mon, 27 Nov 2023 10:25:55 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YoN-0001r5-0N; Mon, 27 Nov 2023 10:25:55 +0000 Received: by outflank-mailman (input) for mailman id 641730; Mon, 27 Nov 2023 10:25:54 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YoM-0000Co-DD for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:25:54 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 57f39661-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:25:53 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 3930321B08; Mon, 27 Nov 2023 10:25:53 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 0F484132A6; Mon, 27 Nov 2023 10:25:53 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id kz+JArFuZGWXfgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:25:53 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 57f39661-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 05/32] Mini-OS: add EXPORT_SYMBOL() instances to sched.c Date: Mon, 27 Nov 2023 11:24:56 +0100 Message-Id: <20231127102523.28003-6-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: +++++++++++++++++++++ Authentication-Results: smtp-out1.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out1.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Rspamd-Server: rspamd2 X-Spamd-Result: default: False [21.50 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; MX_GOOD(-0.01)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; ARC_NA(0.00)[]; R_SPF_FAIL(1.00)[-all]; FROM_HAS_DN(0.00)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(3.00)[1.000]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; RCVD_TLS_ALL(0.00)[] X-Rspamd-Queue-Id: 3930321B08 Add the needed instances of EXPORT_SYMBOL() to sched.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- arch/x86/sched.c | 5 +++++ sched.c | 7 +++++++ 2 files changed, 12 insertions(+) diff --git a/arch/x86/sched.c b/arch/x86/sched.c index e7b6954e..dabe6fd6 100644 --- a/arch/x86/sched.c +++ b/arch/x86/sched.c @@ -142,11 +142,13 @@ unsigned long __local_irq_save(void) local_irq_save(flags); return flags; } +EXPORT_SYMBOL(__local_irq_save); void __local_irq_restore(unsigned long flags) { local_irq_restore(flags); } +EXPORT_SYMBOL(__local_irq_restore); unsigned long __local_save_flags(void) { @@ -155,13 +157,16 @@ unsigned long __local_save_flags(void) local_save_flags(flags); return flags; } +EXPORT_SYMBOL(__local_save_flags); void __local_irq_disable(void) { local_irq_disable(); } +EXPORT_SYMBOL(__local_irq_disable); void __local_irq_enable(void) { local_irq_enable(); } +EXPORT_SYMBOL(__local_irq_enable); diff --git a/sched.c b/sched.c index 6f89ea4d..e162cb60 100644 --- a/sched.c +++ b/sched.c @@ -128,6 +128,7 @@ void schedule(void) } } } +EXPORT_SYMBOL(schedule); struct thread* create_thread(char *name, void (*function)(void *), void *data) { @@ -147,6 +148,7 @@ struct thread* create_thread(char *name, void (*function)(void *), void *data) local_irq_restore(flags); return thread; } +EXPORT_SYMBOL(create_thread); #ifdef HAVE_LIBC static struct _reent callback_reent; @@ -184,6 +186,7 @@ struct _reent *__getreent(void) #endif return _reent; } +EXPORT_SYMBOL(__getreent); #endif void exit_thread(void) @@ -205,12 +208,14 @@ void exit_thread(void) printk("schedule() returned! Trying again\n"); } } +EXPORT_SYMBOL(exit_thread); void block(struct thread *thread) { thread->wakeup_time = 0LL; clear_runnable(thread); } +EXPORT_SYMBOL(block); void msleep(uint32_t millisecs) { @@ -219,12 +224,14 @@ void msleep(uint32_t millisecs) clear_runnable(thread); schedule(); } +EXPORT_SYMBOL(msleep); void wake(struct thread *thread) { thread->wakeup_time = 0LL; set_runnable(thread); } +EXPORT_SYMBOL(wake); void idle_thread_fn(void *unused) { From patchwork Mon Nov 27 10:24:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469335 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 28902C4167B for ; Mon, 27 Nov 2023 10:37:04 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641808.1000743 (Exim 4.92) (envelope-from ) id 1r7Yyw-0004Ps-HA; Mon, 27 Nov 2023 10:36:50 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641808.1000743; Mon, 27 Nov 2023 10:36:50 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yyw-0004P2-DB; Mon, 27 Nov 2023 10:36:50 +0000 Received: by outflank-mailman (input) for mailman id 641808; Mon, 27 Nov 2023 10:36:49 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YoS-0000Co-8B for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:26:00 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 5b43082a-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:25:59 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id B939E21B08; Mon, 27 Nov 2023 10:25:58 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 90147132A6; Mon, 27 Nov 2023 10:25:58 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id 8XjpIbZuZGWffgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:25:58 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 5b43082a-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 06/32] Mini-OS: add EXPORT_SYMBOL() instances to mm.c Date: Mon, 27 Nov 2023 11:24:57 +0100 Message-Id: <20231127102523.28003-7-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: +++++++++++++++++++++ Authentication-Results: smtp-out1.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out1.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Rspamd-Server: rspamd2 X-Spamd-Result: default: False [21.50 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_FAIL(1.00)[-all]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; BROKEN_CONTENT_TYPE(1.50)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; NEURAL_SPAM_SHORT(3.00)[1.000]; MX_GOOD(-0.01)[]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] X-Rspamd-Queue-Id: B939E21B08 Add the needed instances of EXPORT_SYMBOL() to mm.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- arch/arm/mm.c | 2 ++ arch/x86/mm.c | 5 +++++ mm.c | 4 ++++ 3 files changed, 11 insertions(+) diff --git a/arch/arm/mm.c b/arch/arm/mm.c index 11962f8b..c269ab14 100644 --- a/arch/arm/mm.c +++ b/arch/arm/mm.c @@ -85,6 +85,7 @@ int do_map_frames(unsigned long addr, { return -ENOSYS; } +EXPORT_SYMBOL(do_map_frames); /* Get Xen's suggested physical page assignments for the grant table. */ static paddr_t get_gnttab_base(void) @@ -149,3 +150,4 @@ unsigned long map_frame_virt(unsigned long mfn) { return mfn_to_virt(mfn); } +EXPORT_SYMBOL(map_frame_virt); diff --git a/arch/x86/mm.c b/arch/x86/mm.c index cfc978f6..767a5f07 100644 --- a/arch/x86/mm.c +++ b/arch/x86/mm.c @@ -493,6 +493,7 @@ pgentry_t *need_pgt(unsigned long va) offset = l1_table_offset(va); return &tab[offset]; } +EXPORT_SYMBOL(need_pgt); /* * Reserve an area of virtual address space for mappings and Heap @@ -634,6 +635,7 @@ int do_map_frames(unsigned long va, return 0; } +EXPORT_SYMBOL(do_map_frames); /* * Map an array of MFNs contiguous into virtual address space. Virtual @@ -654,6 +656,7 @@ void *map_frames_ex(const unsigned long *mfns, unsigned long n, return (void *)va; } +EXPORT_SYMBOL(map_frames_ex); /* * Unmap nun_frames frames mapped at virtual address va. @@ -724,6 +727,7 @@ int unmap_frames(unsigned long va, unsigned long num_frames) } return 0; } +EXPORT_SYMBOL(unmap_frames); /* * Clear some of the bootstrap memory @@ -859,3 +863,4 @@ unsigned long map_frame_virt(unsigned long mfn) return addr; } +EXPORT_SYMBOL(map_frame_virt); diff --git a/mm.c b/mm.c index 6493bdd4..eb0e34de 100644 --- a/mm.c +++ b/mm.c @@ -280,6 +280,7 @@ unsigned long alloc_pages(int order) return 0; } +EXPORT_SYMBOL(alloc_pages); void free_pages(void *pointer, int order) { @@ -336,6 +337,7 @@ void free_pages(void *pointer, int order) free_head[order] = freed_ch; } +EXPORT_SYMBOL(free_pages); int free_physical_pages(xen_pfn_t *mfns, int n) { @@ -352,6 +354,7 @@ int map_frame_rw(unsigned long addr, unsigned long mfn) { return do_map_frames(addr, &mfn, 1, 1, 1, DOMID_SELF, NULL, L1_PROT); } +EXPORT_SYMBOL(map_frame_rw); #ifdef HAVE_LIBC void *sbrk(ptrdiff_t increment) @@ -385,6 +388,7 @@ void *sbrk(ptrdiff_t increment) return (void *) old_brk; } +EXPORT_SYMBOL(sbrk); #endif From patchwork Mon Nov 27 10:24:58 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469332 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6B2D4C4167B for ; Mon, 27 Nov 2023 10:36:28 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641786.1000686 (Exim 4.92) (envelope-from ) id 1r7YyN-0001Gg-4Q; Mon, 27 Nov 2023 10:36:15 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641786.1000686; Mon, 27 Nov 2023 10:36:15 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YyM-0001Ft-V9; Mon, 27 Nov 2023 10:36:14 +0000 Received: by outflank-mailman (input) for mailman id 641786; Mon, 27 Nov 2023 10:36:13 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yoa-0008NG-Ff for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:26:08 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 5e9486b0-8d0f-11ee-9b0e-b553b5be7939; Mon, 27 Nov 2023 11:26:04 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 4ABDB21B08; Mon, 27 Nov 2023 10:26:04 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 1CA9F132A6; Mon, 27 Nov 2023 10:26:04 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id LgK8BbxuZGWnfgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:26:04 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 5e9486b0-8d0f-11ee-9b0e-b553b5be7939 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 07/32] Mini-OS: add EXPORT_SYMBOL() instances to lib/sys.c Date: Mon, 27 Nov 2023 11:24:58 +0100 Message-Id: <20231127102523.28003-8-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: +++++++++++++++++++++ Authentication-Results: smtp-out1.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out1.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Rspamd-Server: rspamd2 X-Spamd-Result: default: False [21.50 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_FAIL(1.00)[-all]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; BROKEN_CONTENT_TYPE(1.50)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; NEURAL_SPAM_SHORT(3.00)[1.000]; MX_GOOD(-0.01)[]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[]; BAYES_HAM(-3.00)[100.00%] X-Rspamd-Queue-Id: 4ABDB21B08 Add the needed instances of EXPORT_SYMBOL() to lib/sys.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- lib/sys.c | 92 ++++++++++++++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 87 insertions(+), 5 deletions(-) diff --git a/lib/sys.c b/lib/sys.c index 118fc441..481067f7 100644 --- a/lib/sys.c +++ b/lib/sys.c @@ -20,6 +20,7 @@ #ifdef HAVE_LIBC #include +#include #include #include #include @@ -63,7 +64,8 @@ { \ print_unsupported(#function); \ do_exit(); \ - } + } \ + EXPORT_SYMBOL(function) /* Log and err out on function call */ #define unsupported_function_log(type, function, ret) \ @@ -73,7 +75,8 @@ print_unsupported(#function); \ errno = ENOSYS; \ return ret; \ - } + } \ + EXPORT_SYMBOL(function) /* Err out on function call */ #define unsupported_function(type, function, ret) \ @@ -82,7 +85,8 @@ { \ errno = ENOSYS; \ return ret; \ - } + } \ + EXPORT_SYMBOL(function) #define NOFILE 32 #define N_MOUNTS 16 @@ -187,6 +191,7 @@ unsigned int alloc_file_type(const struct file_ops *ops) return ret; } +EXPORT_SYMBOL(alloc_file_type); static const struct file_ops *get_file_ops(unsigned int type) { @@ -203,8 +208,10 @@ struct file *get_file_from_fd(int fd) return (files[fd].type == FTYPE_NONE) ? NULL : files + fd; } +EXPORT_SYMBOL(get_file_from_fd); DECLARE_WAIT_QUEUE_HEAD(event_queue); +EXPORT_SYMBOL(event_queue); int alloc_fd(unsigned int type) { @@ -222,6 +229,7 @@ int alloc_fd(unsigned int type) printk("Too many opened files\n"); do_exit(); } +EXPORT_SYMBOL(alloc_fd); void close_all_files(void) { @@ -232,6 +240,7 @@ void close_all_files(void) close(i); pthread_mutex_unlock(&fd_lock); } +EXPORT_SYMBOL(close_all_files); int dup2(int oldfd, int newfd) { @@ -243,33 +252,39 @@ int dup2(int oldfd, int newfd) pthread_mutex_unlock(&fd_lock); return 0; } +EXPORT_SYMBOL(dup2); pid_t getpid(void) { return 1; } +EXPORT_SYMBOL(getpid); pid_t getppid(void) { return 1; } +EXPORT_SYMBOL(getppid); pid_t setsid(void) { return 1; } +EXPORT_SYMBOL(setsid); char *getcwd(char *buf, size_t size) { snprintf(buf, size, "/"); return buf; } +EXPORT_SYMBOL(getcwd); int mkdir(const char *pathname, mode_t mode) { errno = EIO; return -1; } +EXPORT_SYMBOL(mkdir); #ifdef CONFIG_CONSFRONT int posix_openpt(int flags) @@ -282,6 +297,7 @@ int posix_openpt(int flags) return fd; } +EXPORT_SYMBOL(posix_openpt); static int open_pt(struct mount_point *mnt, const char *pathname, int flags, mode_t mode) @@ -313,6 +329,8 @@ int posix_openpt(int flags) errno = EIO; return -1; } +EXPORT_SYMBOL(posix_openpt); + int open_savefile(const char *path, int save) { errno = EIO; @@ -378,6 +396,8 @@ int open(const char *pathname, int flags, ...) errno = EIO; return -1; } +EXPORT_SYMBOL(open); +EXPORT_SYMBOL(open64); int mount(const char *path, void *dev, int (*open)(struct mount_point *, const char *, int, mode_t)) @@ -422,6 +442,7 @@ int isatty(int fd) { return files[fd].type == FTYPE_CONSOLE; } +EXPORT_SYMBOL(isatty); int read(int fd, void *buf, size_t nbytes) { @@ -440,6 +461,7 @@ int read(int fd, void *buf, size_t nbytes) errno = EBADF; return -1; } +EXPORT_SYMBOL(read); int write(int fd, const void *buf, size_t nbytes) { @@ -458,6 +480,7 @@ int write(int fd, const void *buf, size_t nbytes) errno = EBADF; return -1; } +EXPORT_SYMBOL(write); off_t lseek_default(struct file *file, off_t offset, int whence) { @@ -510,11 +533,14 @@ off_t lseek(int fd, off_t offset, int whence) errno = ESPIPE; return (off_t) -1; } +EXPORT_SYMBOL(lseek); +EXPORT_SYMBOL(lseek64); int fsync(int fd) { errno = EBADF; return -1; } +EXPORT_SYMBOL(fsync); int close(int fd) { @@ -542,6 +568,7 @@ int close(int fd) errno = EBADF; return -1; } +EXPORT_SYMBOL(close); static void init_stat(struct stat *buf) { @@ -559,6 +586,7 @@ int stat(const char *path, struct stat *buf) errno = EIO; return -1; } +EXPORT_SYMBOL(stat); int fstat(int fd, struct stat *buf) { @@ -579,28 +607,34 @@ int fstat(int fd, struct stat *buf) errno = EBADF; return -1; } +EXPORT_SYMBOL(fstat); +EXPORT_SYMBOL(fstat64); int ftruncate(int fd, off_t length) { errno = EBADF; return -1; } +EXPORT_SYMBOL(ftruncate); int remove(const char *pathname) { errno = EIO; return -1; } +EXPORT_SYMBOL(remove); int unlink(const char *pathname) { return remove(pathname); } +EXPORT_SYMBOL(unlink); int rmdir(const char *pathname) { return remove(pathname); } +EXPORT_SYMBOL(rmdir); int fcntl(int fd, int cmd, ...) { @@ -635,6 +669,7 @@ int fcntl(int fd, int cmd, ...) errno = ENOSYS; return -1; } +EXPORT_SYMBOL(fcntl); DIR *opendir(const char *name) { @@ -648,11 +683,13 @@ DIR *opendir(const char *name) ret->has_more = 1; return ret; } +EXPORT_SYMBOL(opendir); struct dirent *readdir(DIR *dir) { return NULL; } +EXPORT_SYMBOL(readdir); int closedir(DIR *dir) { @@ -664,6 +701,7 @@ int closedir(DIR *dir) free(dir); return 0; } +EXPORT_SYMBOL(closedir); /* We assume that only the main thread calls select(). */ @@ -732,6 +770,7 @@ bool select_read_flag(struct file *file) { return file->read; } +EXPORT_SYMBOL(select_read_flag); /* Just poll without blocking */ static int select_poll(int nfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds) @@ -1044,6 +1083,7 @@ out: remove_waiter(console_w, console_queue); return ret; } +EXPORT_SYMBOL(select); /* Wrap around select */ int poll(struct pollfd _pfd[], nfds_t _nfds, int _timeout) @@ -1136,6 +1176,7 @@ int poll(struct pollfd _pfd[], nfds_t _nfds, int _timeout) return n; } +EXPORT_SYMBOL(poll); #ifdef HAVE_LWIP int socket(int domain, int type, int protocol) @@ -1149,6 +1190,7 @@ int socket(int domain, int type, int protocol) files[res].fd = fd; return res; } +EXPORT_SYMBOL(socket); int accept(int s, struct sockaddr *addr, socklen_t *addrlen) { @@ -1166,6 +1208,7 @@ int accept(int s, struct sockaddr *addr, socklen_t *addrlen) printk("accepted on %d -> %d\n", s, res); return res; } +EXPORT_SYMBOL(accept); #define LWIP_STUB(ret, name, proto, args) \ ret name proto \ @@ -1180,15 +1223,25 @@ ret name proto \ } LWIP_STUB(int, bind, (int s, struct sockaddr *my_addr, socklen_t addrlen), (s, my_addr, addrlen)) +EXPORT_SYMBOL(bind); LWIP_STUB(int, getsockopt, (int s, int level, int optname, void *optval, socklen_t *optlen), (s, level, optname, optval, optlen)) +EXPORT_SYMBOL(getsockopt); LWIP_STUB(int, setsockopt, (int s, int level, int optname, void *optval, socklen_t optlen), (s, level, optname, optval, optlen)) +EXPORT_SYMBOL(setsockopt); LWIP_STUB(int, connect, (int s, struct sockaddr *serv_addr, socklen_t addrlen), (s, serv_addr, addrlen)) +EXPORT_SYMBOL(connect); LWIP_STUB(int, listen, (int s, int backlog), (s, backlog)); +EXPORT_SYMBOL(listen); LWIP_STUB(ssize_t, recv, (int s, void *buf, size_t len, int flags), (s, buf, len, flags)) +EXPORT_SYMBOL(recv); LWIP_STUB(ssize_t, recvfrom, (int s, void *buf, size_t len, int flags, struct sockaddr *from, socklen_t *fromlen), (s, buf, len, flags, from, fromlen)) +EXPORT_SYMBOL(recvfrom); LWIP_STUB(ssize_t, send, (int s, void *buf, size_t len, int flags), (s, buf, len, flags)) +EXPORT_SYMBOL(send); LWIP_STUB(ssize_t, sendto, (int s, void *buf, size_t len, int flags, struct sockaddr *to, socklen_t tolen), (s, buf, len, flags, to, tolen)) +EXPORT_SYMBOL(sendto); LWIP_STUB(int, getsockname, (int s, struct sockaddr *name, socklen_t *namelen), (s, name, namelen)) +EXPORT_SYMBOL(getsockname); #endif static char *syslog_ident; @@ -1197,12 +1250,14 @@ void openlog(const char *ident, int option, int facility) free(syslog_ident); syslog_ident = strdup(ident); } +EXPORT_SYMBOL(openlog); void vsyslog(int priority, const char *format, va_list ap) { printk("%s: ", syslog_ident); print(0, format, ap); } +EXPORT_SYMBOL(vsyslog); void syslog(int priority, const char *format, ...) { @@ -1211,12 +1266,14 @@ void syslog(int priority, const char *format, ...) vsyslog(priority, format, ap); va_end(ap); } +EXPORT_SYMBOL(syslog); void closelog(void) { free(syslog_ident); syslog_ident = NULL; } +EXPORT_SYMBOL(closelog); void vwarn(const char *format, va_list ap) { @@ -1228,6 +1285,7 @@ void vwarn(const char *format, va_list ap) } printk("%s", strerror(the_errno)); } +EXPORT_SYMBOL(vwarn); void warn(const char *format, ...) { @@ -1236,12 +1294,14 @@ void warn(const char *format, ...) vwarn(format, ap); va_end(ap); } +EXPORT_SYMBOL(warn); void verr(int eval, const char *format, va_list ap) { vwarn(format, ap); exit(eval); } +EXPORT_SYMBOL(verr); void err(int eval, const char *format, ...) { @@ -1250,6 +1310,7 @@ void err(int eval, const char *format, ...) verr(eval, format, ap); va_end(ap); } +EXPORT_SYMBOL(err); void vwarnx(const char *format, va_list ap) { @@ -1257,6 +1318,7 @@ void vwarnx(const char *format, va_list ap) if (format) print(0, format, ap); } +EXPORT_SYMBOL(vwarnx); void warnx(const char *format, ...) { @@ -1265,12 +1327,14 @@ void warnx(const char *format, ...) vwarnx(format, ap); va_end(ap); } +EXPORT_SYMBOL(warnx); void verrx(int eval, const char *format, va_list ap) { vwarnx(format, ap); exit(eval); } +EXPORT_SYMBOL(verrx); void errx(int eval, const char *format, ...) { @@ -1279,6 +1343,7 @@ void errx(int eval, const char *format, ...) verrx(eval, format, ap); va_end(ap); } +EXPORT_SYMBOL(errx); int nanosleep(const struct timespec *req, struct timespec *rem) { @@ -1304,6 +1369,7 @@ int nanosleep(const struct timespec *req, struct timespec *rem) return 0; } +EXPORT_SYMBOL(nanosleep); int usleep(useconds_t usec) { @@ -1317,6 +1383,7 @@ int usleep(useconds_t usec) return 0; } +EXPORT_SYMBOL(usleep); unsigned int sleep(unsigned int seconds) { @@ -1332,6 +1399,7 @@ unsigned int sleep(unsigned int seconds) return rem.tv_sec; } +EXPORT_SYMBOL(sleep); int clock_gettime(clockid_t clk_id, struct timespec *tp) { @@ -1364,37 +1432,44 @@ int clock_gettime(clockid_t clk_id, struct timespec *tp) return 0; } +EXPORT_SYMBOL(clock_gettime); uid_t getuid(void) { return 0; } +EXPORT_SYMBOL(getuid); uid_t geteuid(void) { return 0; } +EXPORT_SYMBOL(geteuid); gid_t getgid(void) { return 0; } +EXPORT_SYMBOL(getgid); gid_t getegid(void) { return 0; } +EXPORT_SYMBOL(getegid); int gethostname(char *name, size_t namelen) { strncpy(name, "mini-os", namelen); return 0; } +EXPORT_SYMBOL(gethostname); size_t getpagesize(void) { return PAGE_SIZE; } +EXPORT_SYMBOL(getpagesize); void *mmap(void *start, size_t length, int prot, int flags, int fd, off_t offset) { @@ -1412,6 +1487,8 @@ void *mmap(void *start, size_t length, int prot, int flags, int fd, off_t offset return map_frames_ex(&first_mfn, n, 0, 1, 1, DOMID_IO, NULL, _PAGE_PRESENT|_PAGE_RW); } else ASSERT(0); } +EXPORT_SYMBOL(mmap); +EXPORT_SYMBOL(mmap64); int munmap(void *start, size_t length) { @@ -1425,6 +1502,7 @@ int munmap(void *start, size_t length) } return 0; } +EXPORT_SYMBOL(munmap); void sparse(unsigned long data, size_t size) { @@ -1465,6 +1543,7 @@ int nice(int inc) printk("nice() stub called with inc=%d\n", inc); return 0; } +EXPORT_SYMBOL(nice); /* Limited termios terminal settings support */ const struct termios default_termios = {0, /* iflag */ @@ -1512,6 +1591,7 @@ int tcsetattr(int fildes, int action, const struct termios *tios) return 0; } +EXPORT_SYMBOL(tcsetattr); int tcgetattr(int fildes, struct termios *tios) { @@ -1545,6 +1625,7 @@ int tcgetattr(int fildes, struct termios *tios) return 0; } +EXPORT_SYMBOL(tcgetattr); void cfmakeraw(struct termios *tios) { @@ -1555,6 +1636,7 @@ void cfmakeraw(struct termios *tios) tios->c_cflag &= ~(CSIZE | PARENB); tios->c_cflag |= CS8; } +EXPORT_SYMBOL(cfmakeraw); /* Not supported by FS yet. */ unsupported_function_crash(link); @@ -1659,8 +1741,8 @@ unsupported_function_log(int, ftruncate64, -1); unsupported_function_log(int, fchown, -1); unsupported_function_log(int, fchmod, -1); unsupported_function_crash(execvp); -unsupported_function_log(int, dup, -1) -unsupported_function_log(int, chroot, -1) +unsupported_function_log(int, dup, -1); +unsupported_function_log(int, chroot, -1); unsupported_function_log(int, chown, -1); unsupported_function_log(int, chmod, -1); unsupported_function_crash(alarm); From patchwork Mon Nov 27 10:24:59 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469348 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 51D62C4167B for ; Mon, 27 Nov 2023 10:40:07 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641893.1000895 (Exim 4.92) (envelope-from ) id 1r7Z1v-00035k-B5; Mon, 27 Nov 2023 10:39:55 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641893.1000895; Mon, 27 Nov 2023 10:39:55 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z1v-00035X-7u; Mon, 27 Nov 2023 10:39:55 +0000 Received: by outflank-mailman (input) for mailman id 641893; Mon, 27 Nov 2023 10:39:53 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yoe-0000Co-EC for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:26:12 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 61d40f72-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:26:10 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id CB4AA21B08; Mon, 27 Nov 2023 10:26:09 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id A145E132A6; Mon, 27 Nov 2023 10:26:09 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id wlYeJsFuZGWyfgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:26:09 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 61d40f72-8d0f-11ee-98e2-6d05b1d4d9a1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080769; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=IWD9wp7e1oDERY6EogAJmEZnMVVQ68S78bsckAXuJSQ=; b=mLeiD3dNhIcEs2Z5Pm6u+uA1RJoffr7sg/iuIZ0VeVkYVSgg52ytLyBNM9niK/PZ5VW5Yt iKVSQ5ALKVsXR5030f7xVXKnC4APnKErB6lKba2SgTIS7KvesZkJl4hliq3Dj8nhDaw9ju fl/M2tlIoddQ9+rNKxtt1xwMGD0OMhs= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 08/32] Mini-OS: add EXPORT_SYMBOL() instances to lib/string.c Date: Mon, 27 Nov 2023 11:24:59 +0100 Message-Id: <20231127102523.28003-9-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out1.suse.de; none X-Spamd-Result: default: False [16.50 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(5.10)[100.00%]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_SHORT(3.00)[1.000]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to lib/string.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- lib/string.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/lib/string.c b/lib/string.c index 8b241464..b0b628c6 100644 --- a/lib/string.c +++ b/lib/string.c @@ -19,6 +19,7 @@ */ #include +#include /* newlib defines ffs but not ffsll or ffsl */ int __ffsti2 (long long int lli) @@ -49,11 +50,13 @@ int ffsl (long int li) { return __ffsti2 ((long long int) li); } +EXPORT_SYMBOL(ffsl); int ffsll (long long int lli) { return __ffsti2 (lli); } +EXPORT_SYMBOL(ffsll); #if !defined HAVE_LIBC @@ -72,6 +75,7 @@ int memcmp(const void * cs,const void * ct,size_t count) break; return res; } +EXPORT_SYMBOL(memcmp); void * memcpy(void * dest,const void *src,size_t count) { @@ -83,6 +87,7 @@ void * memcpy(void * dest,const void *src,size_t count) return dest; } +EXPORT_SYMBOL(memcpy); int strncmp(const char * cs,const char * ct,size_t count) { @@ -96,6 +101,7 @@ int strncmp(const char * cs,const char * ct,size_t count) return __res; } +EXPORT_SYMBOL(strncmp); int strcmp(const char * cs,const char * ct) { @@ -108,6 +114,7 @@ int strcmp(const char * cs,const char * ct) return __res; } +EXPORT_SYMBOL(strcmp); char * strcpy(char * dest,const char *src) { @@ -117,6 +124,7 @@ char * strcpy(char * dest,const char *src) /* nothing */; return tmp; } +EXPORT_SYMBOL(strcpy); char * strncpy(char * dest,const char *src,size_t count) { @@ -127,6 +135,7 @@ char * strncpy(char * dest,const char *src,size_t count) return tmp; } +EXPORT_SYMBOL(strncpy); void * memset(void * s,int c,size_t count) { @@ -137,6 +146,7 @@ void * memset(void * s,int c,size_t count) return s; } +EXPORT_SYMBOL(memset); size_t strnlen(const char * s, size_t count) { @@ -146,6 +156,7 @@ size_t strnlen(const char * s, size_t count) /* nothing */; return sc - s; } +EXPORT_SYMBOL(strnlen); char * strcat(char * dest, const char * src) @@ -159,6 +170,7 @@ char * strcat(char * dest, const char * src) return tmp; } +EXPORT_SYMBOL(strcat); size_t strlen(const char * s) { @@ -168,6 +180,7 @@ size_t strlen(const char * s) /* nothing */; return sc - s; } +EXPORT_SYMBOL(strlen); char * strchr(const char * s, int c) { @@ -176,6 +189,7 @@ char * strchr(const char * s, int c) return NULL; return (char *)s; } +EXPORT_SYMBOL(strchr); char * strrchr(const char * s, int c) { @@ -185,6 +199,7 @@ char * strrchr(const char * s, int c) res = s; return (char *)res; } +EXPORT_SYMBOL(strrchr); char * strstr(const char * s1,const char * s2) { @@ -202,6 +217,7 @@ char * strstr(const char * s1,const char * s2) } return NULL; } +EXPORT_SYMBOL(strstr); char *strdup(const char *x) { @@ -211,6 +227,7 @@ char *strdup(const char *x) memcpy(res, x, l + 1); return res; } +EXPORT_SYMBOL(strdup); int ffs(int i) { @@ -224,5 +241,6 @@ int ffs(int i) } while (i); return 0; } +EXPORT_SYMBOL(ffs); #endif From patchwork Mon Nov 27 10:25:00 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469339 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 20A41C07D5A for ; Mon, 27 Nov 2023 10:37:36 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641822.1000761 (Exim 4.92) (envelope-from ) id 1r7YzX-0005fm-SZ; Mon, 27 Nov 2023 10:37:27 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641822.1000761; Mon, 27 Nov 2023 10:37:27 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YzX-0005ff-P9; Mon, 27 Nov 2023 10:37:27 +0000 Received: by outflank-mailman (input) for mailman id 641822; Mon, 27 Nov 2023 10:37:26 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yoj-0000Co-Hl for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:26:17 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 651adca2-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:26:15 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 5714D21B08; Mon, 27 Nov 2023 10:26:15 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 2D7B1132A6; Mon, 27 Nov 2023 10:26:15 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id ARfVCcduZGW1fgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:26:15 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 651adca2-8d0f-11ee-98e2-6d05b1d4d9a1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080775; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=0DRQp+amWyFgc15qgsA7zVmZocwANgk7w1gaKIUS3eY=; b=d5MvaSh4q9nCVYwqr++Wx8UgiX7f6CC2PE4OGZgo2LW/fPYdtLx5j5wncG7/YYT87kEQJT tePy0SXfyF8EECUPGw5FYhM/bztxtBYwxGtGUMZ9idU+BlEbfXYj15Cvb1GAqgQbzZTLa4 poPn5xzk9p54DzwuLPREzUi7oqaDYos= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 09/32] Mini-OS: add EXPORT_SYMBOL() instances to lib/math.c Date: Mon, 27 Nov 2023 11:25:00 +0100 Message-Id: <20231127102523.28003-10-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out1.suse.de; none X-Spamd-Result: default: False [11.43 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(0.03)[52.25%]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_SHORT(3.00)[1.000]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to lib/math.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- lib/math.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/math.c b/lib/math.c index b98cc1d2..9ee9fcdb 100644 --- a/lib/math.c +++ b/lib/math.c @@ -338,6 +338,7 @@ __qdivrem(u_quad_t uq, u_quad_t vq, u_quad_t *arq) tmp.ul[L] = COMBINE(qspace[3], qspace[4]); return (tmp.q); } +EXPORT_SYMBOL(__qdivrem); /* * From @@ -365,6 +366,7 @@ __divdi3(quad_t a, quad_t b) uq = __qdivrem(ua, ub, (u_quad_t *)0); return (neg ? -uq : uq); } +EXPORT_SYMBOL(__divdi3); /* * From @@ -379,6 +381,7 @@ __udivdi3(u_quad_t a, u_quad_t b) { return (__qdivrem(a, b, (u_quad_t *)0)); } +EXPORT_SYMBOL(__udivdi3); /* * From @@ -396,6 +399,7 @@ __umoddi3(u_quad_t a, u_quad_t b) (void)__qdivrem(a, b, &r); return (r); } +EXPORT_SYMBOL(__umoddi3); /* * Returns the quotient and places remainder in r @@ -405,6 +409,7 @@ __udivmoddi4(u_quad_t a, u_quad_t b, u_quad_t *r) { return __qdivrem(a, b, r); } +EXPORT_SYMBOL(__udivmoddi4); /* * From @@ -434,3 +439,4 @@ __moddi3(quad_t a, quad_t b) (void)__qdivrem(ua, ub, &ur); return (neg ? -ur : ur); } +EXPORT_SYMBOL(__moddi3); From patchwork Mon Nov 27 10:25:01 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469343 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 0E852C07D5A for ; Mon, 27 Nov 2023 10:38:53 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641855.1000821 (Exim 4.92) (envelope-from ) id 1r7Z0o-0008Qe-B2; Mon, 27 Nov 2023 10:38:46 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641855.1000821; Mon, 27 Nov 2023 10:38:46 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z0o-0008QT-7f; Mon, 27 Nov 2023 10:38:46 +0000 Received: by outflank-mailman (input) for mailman id 641855; Mon, 27 Nov 2023 10:38:45 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yoo-0000Co-75 for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:26:22 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 6865c561-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:26:21 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id D80AA21A5E; Mon, 27 Nov 2023 10:26:20 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id AEEAA132A6; Mon, 27 Nov 2023 10:26:20 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id JriAKcxuZGW3fgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:26:20 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 6865c561-8d0f-11ee-98e2-6d05b1d4d9a1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080780; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ktKhOGmur4jQ1Brbb0nDkjWoCytuJc3+OYR5hECH7CE=; b=IjYs3Cs2b2fDJ3zRFhwBZ2fdsjgytBwFlhVyufPK6Kks/dxRbKSpbdlKH+yCrYRmlsjoI6 FDaSPq0TJBmoKfP94ajBemev0J17uiv40Ca4NESo7mvgs7+88VfKCSBVo18EHNxgam5/Oe fc/+FfV8ugeqZS1kaWzBBK+VAtajTCA= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 10/32] Mini-OS: add EXPORT_SYMBOL() instances to lib/printf.c Date: Mon, 27 Nov 2023 11:25:01 +0100 Message-Id: <20231127102523.28003-11-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out1.suse.de; none X-Spamd-Result: default: False [11.40 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_SHORT(3.00)[1.000]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to lib/printf.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- lib/printf.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/lib/printf.c b/lib/printf.c index f9e9d682..0e054957 100644 --- a/lib/printf.c +++ b/lib/printf.c @@ -150,6 +150,7 @@ strtoul(const char *nptr, char **endptr, int base) *endptr = __DECONST(char *, any ? s - 1 : nptr); return (acc); } +EXPORT_SYMBOL(strtoul); /* * Convert a string to a quad integer. @@ -241,6 +242,7 @@ strtoq(const char *nptr, char **endptr, int base) *endptr = __DECONST(char *, any ? s - 1 : nptr); return (acc); } +EXPORT_SYMBOL(strtoq); /* * Convert a string to an unsigned quad integer. @@ -309,6 +311,7 @@ strtouq(const char *nptr, char **endptr, int base) *endptr = __DECONST(char *, any ? s - 1 : nptr); return (acc); } +EXPORT_SYMBOL(strtouq); /* * Scaled down version of printf(3). @@ -585,6 +588,7 @@ number: } #undef PCHAR } +EXPORT_SYMBOL(vsnprintf); /** * snprintf - Format a string and place it in a buffer @@ -603,6 +607,7 @@ int snprintf(char * buf, size_t size, const char *fmt, ...) va_end(args); return i; } +EXPORT_SYMBOL(snprintf); /** * vsprintf - Format a string and place it in a buffer @@ -617,7 +622,7 @@ int vsprintf(char *buf, const char *fmt, va_list args) { return vsnprintf(buf, 0xFFFFFFFFUL, fmt, args); } - +EXPORT_SYMBOL(vsprintf); /** * sprintf - Format a string and place it in a buffer @@ -635,6 +640,7 @@ int sprintf(char * buf, const char *fmt, ...) va_end(args); return i; } +EXPORT_SYMBOL(sprintf); /* * Fill in the given table from the scanset at the given format @@ -1214,6 +1220,7 @@ input_failure: match_failure: return (nassigned); } +EXPORT_SYMBOL(vsscanf); /** * sscanf - Unformat a buffer into a list of arguments @@ -1231,5 +1238,6 @@ int sscanf(const char * buf, const char * fmt, ...) va_end(args); return i; } +EXPORT_SYMBOL(sscanf); #endif From patchwork Mon Nov 27 10:25:02 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469329 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 851C9C4167B for ; Mon, 27 Nov 2023 10:36:16 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641780.1000661 (Exim 4.92) (envelope-from ) id 1r7YyG-0000XW-AQ; Mon, 27 Nov 2023 10:36:08 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641780.1000661; Mon, 27 Nov 2023 10:36:08 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YyG-0000XN-7b; Mon, 27 Nov 2023 10:36:08 +0000 Received: by outflank-mailman (input) for mailman id 641780; Mon, 27 Nov 2023 10:36:07 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7You-0000Co-P2 for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:26:28 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 6bd6d5a2-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:26:27 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 5C5DC21A5E; Mon, 27 Nov 2023 10:26:26 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 3392A132A6; Mon, 27 Nov 2023 10:26:26 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id BPdEC9JuZGXBfgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:26:26 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 6bd6d5a2-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 11/32] Mini-OS: add EXPORT_SYMBOL() instances to lib/ctype.c Date: Mon, 27 Nov 2023 11:25:02 +0100 Message-Id: <20231127102523.28003-12-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: ++++++++++++++++++++++++++ Authentication-Results: smtp-out1.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out1.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Rspamd-Server: rspamd2 X-Spamd-Result: default: False [26.53 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_FAIL(1.00)[-all]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; BROKEN_CONTENT_TYPE(1.50)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; BAYES_SPAM(5.03)[99.83%]; NEURAL_SPAM_SHORT(3.00)[1.000]; MX_GOOD(-0.01)[]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] X-Rspamd-Queue-Id: 5C5DC21A5E Add the needed instances of EXPORT_SYMBOL() to lib/ctype.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- lib/ctype.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/ctype.c b/lib/ctype.c index 3f3bdb00..309ebbc9 100644 --- a/lib/ctype.c +++ b/lib/ctype.c @@ -1,5 +1,6 @@ #ifndef HAVE_LIBC #include +#include unsigned char _ctype[] = { _C,_C,_C,_C,_C,_C,_C,_C, /* 0-7 */ @@ -26,4 +27,5 @@ _U,_U,_U,_U,_U,_U,_U,_U,_U,_U,_U,_U,_U,_U,_U,_U, /* 192-207 */ _U,_U,_U,_U,_U,_U,_U,_P,_U,_U,_U,_U,_U,_U,_U,_L, /* 208-223 */ _L,_L,_L,_L,_L,_L,_L,_L,_L,_L,_L,_L,_L,_L,_L,_L, /* 224-239 */ _L,_L,_L,_L,_L,_L,_L,_P,_L,_L,_L,_L,_L,_L,_L,_L}; /* 240-255 */ +EXPORT_SYMBOL(_ctype); #endif From patchwork Mon Nov 27 10:25:03 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469333 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 9F081C4167B for ; Mon, 27 Nov 2023 10:36:42 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641795.1000701 (Exim 4.92) (envelope-from ) id 1r7Yyf-0002jM-H4; Mon, 27 Nov 2023 10:36:33 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641795.1000701; Mon, 27 Nov 2023 10:36:33 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yyf-0002jA-E5; Mon, 27 Nov 2023 10:36:33 +0000 Received: by outflank-mailman (input) for mailman id 641795; Mon, 27 Nov 2023 10:36:32 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yp0-0000Co-CD for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:26:34 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 6f0520a5-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:26:32 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id DBD3D21A5E; Mon, 27 Nov 2023 10:26:31 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id B436D132A6; Mon, 27 Nov 2023 10:26:31 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id AyvGKtduZGXFfgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:26:31 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 6f0520a5-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 12/32] Mini-OS: add EXPORT_SYMBOL() instances to lib/xmalloc.c Date: Mon, 27 Nov 2023 11:25:03 +0100 Message-Id: <20231127102523.28003-13-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: ++++++++++++++++++++++ Authentication-Results: smtp-out1.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out1.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Rspamd-Server: rspamd2 X-Spamd-Result: default: False [22.92 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(1.42)[85.25%]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; MX_GOOD(-0.01)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; ARC_NA(0.00)[]; R_SPF_FAIL(1.00)[-all]; FROM_HAS_DN(0.00)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(3.00)[1.000]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; RCVD_TLS_ALL(0.00)[] X-Rspamd-Queue-Id: DBD3D21A5E Add the needed instances of EXPORT_SYMBOL() to lib/xmalloc.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- lib/xmalloc.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/xmalloc.c b/lib/xmalloc.c index e16f161a..cc5db11e 100644 --- a/lib/xmalloc.c +++ b/lib/xmalloc.c @@ -271,6 +271,7 @@ void *malloc(size_t size) { return _xmalloc(size, DEFAULT_ALIGN); } +EXPORT_SYMBOL(malloc); void *realloc(void *ptr, size_t size) { @@ -301,11 +302,13 @@ void *realloc(void *ptr, size_t size) return new; } +EXPORT_SYMBOL(realloc); void free(void *ptr) { xfree(ptr); } +EXPORT_SYMBOL(free); #endif /* From patchwork Mon Nov 27 10:25:04 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469331 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D7FD2C4167B for ; Mon, 27 Nov 2023 10:36:23 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641785.1000681 (Exim 4.92) (envelope-from ) id 1r7YyM-0001Dt-Qj; Mon, 27 Nov 2023 10:36:14 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641785.1000681; Mon, 27 Nov 2023 10:36:14 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YyM-0001Dg-Nn; Mon, 27 Nov 2023 10:36:14 +0000 Received: by outflank-mailman (input) for mailman id 641785; Mon, 27 Nov 2023 10:36:13 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yp4-0000Co-JB for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:26:38 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [2a07:de40:b251:101:10:150:64:1]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 723e8f30-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:26:37 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 67E7321A5E; Mon, 27 Nov 2023 10:26:37 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 3F819132A6; Mon, 27 Nov 2023 10:26:37 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id TUghDt1uZGXRfgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:26:37 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 723e8f30-8d0f-11ee-98e2-6d05b1d4d9a1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080797; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=YCGp9mQOcr8NzJb1ZHSNOf2u959zWvLhTh86LYUiIoU=; b=YcD7l7hAG6XaemMopOA8Bd26KS0kRqJBJaiQZdmKGF6ua4h0Z2HRyMlfJojEKuleToI863 uxPRvoBry5Gnnd5sEbKR3h8e6BYYJIbiv0aVWmnqTv1VlxcB8jEfnx1sf53dA+dl04Ztd0 31ZgnNFGOgVkwaKSUhd3Lu5uZphV6N4= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 13/32] Mini-OS: add EXPORT_SYMBOL() instances to lib/xs.c Date: Mon, 27 Nov 2023 11:25:04 +0100 Message-Id: <20231127102523.28003-14-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out1.suse.de; none X-Spamd-Result: default: False [11.40 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_SHORT(3.00)[1.000]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to lib/xs.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- lib/xs.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/lib/xs.c b/lib/xs.c index 7fe9b03e..ff0768c1 100644 --- a/lib/xs.c +++ b/lib/xs.c @@ -64,6 +64,7 @@ struct xs_handle *xs_daemon_open() printk("xs_daemon_open -> %d, %p\n", fd, &file->dev); return (void*)(intptr_t) fd; } +EXPORT_SYMBOL(xs_daemon_open); void xs_daemon_close(struct xs_handle *h) { @@ -74,6 +75,7 @@ int xs_fileno(struct xs_handle *h) { return _xs_fileno(h); } +EXPORT_SYMBOL(xs_fileno); void *xs_read(struct xs_handle *h, xs_transaction_t t, const char *path, unsigned int *len) @@ -92,6 +94,7 @@ void *xs_read(struct xs_handle *h, xs_transaction_t t, *len = strlen(value); return value; } +EXPORT_SYMBOL(xs_read); bool xs_write(struct xs_handle *h, xs_transaction_t t, const char *path, const void *data, unsigned int len) @@ -110,6 +113,7 @@ bool xs_write(struct xs_handle *h, xs_transaction_t t, } return true; } +EXPORT_SYMBOL(xs_write); static bool xs_bool(char *reply) { @@ -123,6 +127,7 @@ bool xs_rm(struct xs_handle *h, xs_transaction_t t, const char *path) { return xs_bool(xenbus_rm(t, path)); } +EXPORT_SYMBOL(xs_rm); static void *xs_talkv(struct xs_handle *h, xs_transaction_t t, enum xsd_sockmsg_type type, @@ -163,6 +168,7 @@ char *xs_get_domain_path(struct xs_handle *h, unsigned int domid) return xs_single(h, XBT_NULL, XS_GET_DOMAIN_PATH, domid_str, NULL); } +EXPORT_SYMBOL(xs_get_domain_path); char **xs_directory(struct xs_handle *h, xs_transaction_t t, const char *path, unsigned int *num) @@ -199,6 +205,7 @@ char **xs_directory(struct xs_handle *h, xs_transaction_t t, free(res); return entries; } +EXPORT_SYMBOL(xs_directory); bool xs_watch(struct xs_handle *h, const char *path, const char *token) { @@ -208,6 +215,7 @@ bool xs_watch(struct xs_handle *h, const char *path, const char *token) return xs_bool(xenbus_watch_path_token(XBT_NULL, path, token, (xenbus_event_queue *)&file->dev)); } +EXPORT_SYMBOL(xs_watch); char **xs_read_watch(struct xs_handle *h, unsigned int *num) { @@ -220,10 +228,12 @@ char **xs_read_watch(struct xs_handle *h, unsigned int *num) *num = 2; return (char **) &event->path; } +EXPORT_SYMBOL(xs_read_watch); bool xs_unwatch(struct xs_handle *h, const char *path, const char *token) { printk("xs_unwatch(%s, %s)\n", path, token); return xs_bool(xenbus_unwatch_path_token(XBT_NULL, path, token)); } +EXPORT_SYMBOL(xs_unwatch); #endif From patchwork Mon Nov 27 10:25:05 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469334 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 631D0C4167B for ; Mon, 27 Nov 2023 10:36:46 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641801.1000725 (Exim 4.92) (envelope-from ) id 1r7Yyj-0003OC-44; Mon, 27 Nov 2023 10:36:37 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641801.1000725; Mon, 27 Nov 2023 10:36:37 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yyi-0003O5-W0; Mon, 27 Nov 2023 10:36:36 +0000 Received: by outflank-mailman (input) for mailman id 641801; Mon, 27 Nov 2023 10:36:35 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YpB-0000Co-1P for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:26:45 +0000 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.223.131]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 758edf24-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:26:43 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id E88C0202A5; Mon, 27 Nov 2023 10:26:42 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id BDCE9132A6; Mon, 27 Nov 2023 10:26:42 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id lesbLeJuZGXXfgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:26:42 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 758edf24-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 14/32] Mini-OS: add EXPORT_SYMBOL() instances to main.c Date: Mon, 27 Nov 2023 11:25:05 +0100 Message-Id: <20231127102523.28003-15-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: +++++++++++++++++ X-Rspamd-Server: rspamd1 X-Rspamd-Queue-Id: E88C0202A5 Authentication-Results: smtp-out2.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out2.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Spamd-Result: default: False [17.93 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_FAIL(1.00)[-all]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; BROKEN_CONTENT_TYPE(1.50)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; RCPT_COUNT_FIVE(0.00)[5]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; BAYES_SPAM(4.13)[97.40%]; MX_GOOD(-0.01)[]; NEURAL_HAM_SHORT(-0.20)[-1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to main.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- main.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/main.c b/main.c index a93bc9d6..c5c1c420 100644 --- a/main.c +++ b/main.c @@ -38,10 +38,12 @@ int main(int argc, char *argv[], char *envp[]) void _init(void) { } +EXPORT_SYMBOL(_init); void _fini(void) { } +EXPORT_SYMBOL(_fini); extern char __app_bss_start, __app_bss_end; static void call_main(void *p) @@ -189,6 +191,7 @@ void _exit(int ret) } do_exit(); } +EXPORT_SYMBOL(_exit); int app_main(void *p) { From patchwork Mon Nov 27 10:25:06 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469342 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4E791C0755A for ; Mon, 27 Nov 2023 10:38:43 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641845.1000807 (Exim 4.92) (envelope-from ) id 1r7Z0Z-0007jo-1r; Mon, 27 Nov 2023 10:38:31 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641845.1000807; Mon, 27 Nov 2023 10:38:31 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z0Y-0007je-UG; Mon, 27 Nov 2023 10:38:30 +0000 Received: by outflank-mailman (input) for mailman id 641845; Mon, 27 Nov 2023 10:38:30 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YpF-0000Co-L5 for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:26:49 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 78dd2f6e-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:26:49 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 75B2B21A5E; Mon, 27 Nov 2023 10:26:48 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 4CBA9132A6; Mon, 27 Nov 2023 10:26:48 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id Q69iEehuZGXdfgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:26:48 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 78dd2f6e-8d0f-11ee-98e2-6d05b1d4d9a1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080808; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=6A+RhPrAAMc0jcGa19Yq756hCQ6xoflSogusd8hsADA=; b=dNH1K448IJdl4+akYaWlEmCY2doQEIYjPj9X8PGJ62TFdVgPIuauGEjZCzNMf0jXp1l6iO BWtBGbqsZxIeXWMlXnemN5An9Mw0NMqRa/BIDdD3c7vGVIgHh5ugXTkwTPnPyMZHXdpb53 1IhGwyYIXMG2hICTs8CzZR4JzON3/xA= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 15/32] Mini-OS: add EXPORT_SYMBOL() instances to console.c Date: Mon, 27 Nov 2023 11:25:06 +0100 Message-Id: <20231127102523.28003-16-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out1.suse.de; none X-Spamd-Result: default: False [11.83 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(0.43)[73.32%]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(3.00)[1.000]; MIME_GOOD(-0.10)[text/plain]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to console.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- console.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/console.c b/console.c index 5d205c7d..0107b685 100644 --- a/console.c +++ b/console.c @@ -125,6 +125,7 @@ void console_print(struct consfront_dev *dev, const char *data, int length) ring_send_fn(dev, copied_ptr, length); } +EXPORT_SYMBOL(console_print); void print(int direct, const char *fmt, va_list args) { @@ -155,6 +156,7 @@ void printk(const char *fmt, ...) print(0, fmt, args); va_end(args); } +EXPORT_SYMBOL(printk); void xprintk(const char *fmt, ...) { @@ -164,6 +166,8 @@ void xprintk(const char *fmt, ...) print(1, fmt, args); va_end(args); } +EXPORT_SYMBOL(xprintk); + void init_console(void) { printk("Initialising console ... "); @@ -320,6 +324,7 @@ int xencons_ring_avail(struct consfront_dev *dev) return prod - cons; } +EXPORT_SYMBOL(xencons_ring_avail); int xencons_ring_recv(struct consfront_dev *dev, char *data, unsigned int len) { From patchwork Mon Nov 27 10:25:07 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469347 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 2E557C07D5A for ; Mon, 27 Nov 2023 10:39:56 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641888.1000885 (Exim 4.92) (envelope-from ) id 1r7Z1o-0002Ww-2p; Mon, 27 Nov 2023 10:39:48 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641888.1000885; Mon, 27 Nov 2023 10:39:48 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z1o-0002Wl-07; Mon, 27 Nov 2023 10:39:48 +0000 Received: by outflank-mailman (input) for mailman id 641888; Mon, 27 Nov 2023 10:39:46 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YpM-0000Co-4I for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:26:56 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 7c2ce034-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:26:54 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 05E6E21A5E; Mon, 27 Nov 2023 10:26:54 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id D122E132A6; Mon, 27 Nov 2023 10:26:53 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id ioJbMe1uZGXhfgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:26:53 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 7c2ce034-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 16/32] Mini-OS: add EXPORT_SYMBOL() instances to events.c Date: Mon, 27 Nov 2023 11:25:07 +0100 Message-Id: <20231127102523.28003-17-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: +++++++++++++++++++++ Authentication-Results: smtp-out1.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out1.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Rspamd-Server: rspamd2 X-Spamd-Result: default: False [21.57 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(0.07)[58.33%]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; MX_GOOD(-0.01)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; ARC_NA(0.00)[]; R_SPF_FAIL(1.00)[-all]; FROM_HAS_DN(0.00)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(3.00)[1.000]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; RCVD_TLS_ALL(0.00)[] X-Rspamd-Queue-Id: 05E6E21A5E Add the needed instances of EXPORT_SYMBOL() to events.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- events.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/events.c b/events.c index 4683e8e1..9f3dbf05 100644 --- a/events.c +++ b/events.c @@ -119,6 +119,7 @@ void unbind_evtchn(evtchn_port_t port ) if ( rc ) printk("WARN: close_port %d failed rc=%d. ignored\n", port, rc); } +EXPORT_SYMBOL(unbind_evtchn); evtchn_port_t bind_virq(uint32_t virq, evtchn_handler_t handler, void *data) { @@ -138,6 +139,7 @@ evtchn_port_t bind_virq(uint32_t virq, evtchn_handler_t handler, void *data) bind_evtchn(op.port, handler, data); return op.port; } +EXPORT_SYMBOL(bind_virq); evtchn_port_t bind_pirq(uint32_t pirq, int will_share, evtchn_handler_t handler, void *data) @@ -157,6 +159,7 @@ evtchn_port_t bind_pirq(uint32_t pirq, int will_share, bind_evtchn(op.port, handler, data); return op.port; } +EXPORT_SYMBOL(bind_pirq); /* * Initially all events are without a handler and disabled @@ -217,6 +220,7 @@ int evtchn_alloc_unbound(domid_t pal, evtchn_handler_t handler, *port = bind_evtchn(op.port, handler, data); return rc; } +EXPORT_SYMBOL(evtchn_alloc_unbound); /* Connect to a port so as to allow the exchange of notifications with the pal. Returns the result of the hypervisor call. */ @@ -240,6 +244,7 @@ int evtchn_bind_interdomain(domid_t pal, evtchn_port_t remote_port, *local_port = bind_evtchn(port, handler, data); return rc; } +EXPORT_SYMBOL(evtchn_bind_interdomain); int evtchn_get_peercontext(evtchn_port_t local_port, char *ctx, int size) { @@ -260,6 +265,7 @@ int evtchn_get_peercontext(evtchn_port_t local_port, char *ctx, int size) rc = HYPERVISOR_xsm_op(&op); return rc; } +EXPORT_SYMBOL(evtchn_get_peercontext); /* Replace below when a hypercall is available to get the domid. */ domid_t get_domid(void) @@ -294,6 +300,7 @@ domid_t get_domid(void) return domid; } +EXPORT_SYMBOL(get_domid); /* * Local variables: From patchwork Mon Nov 27 10:25:08 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469353 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A50C5C0755A for ; Mon, 27 Nov 2023 10:40:48 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641911.1000943 (Exim 4.92) (envelope-from ) id 1r7Z2Y-0006eU-O8; Mon, 27 Nov 2023 10:40:34 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641911.1000943; Mon, 27 Nov 2023 10:40:34 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z2Y-0006eN-L6; Mon, 27 Nov 2023 10:40:34 +0000 Received: by outflank-mailman (input) for mailman id 641911; Mon, 27 Nov 2023 10:40:33 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YpR-0000Co-FN for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:27:01 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [2a07:de40:b251:101:10:150:64:1]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 7f76510e-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:27:00 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 87E5921A5E; Mon, 27 Nov 2023 10:26:59 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 5D66B132A6; Mon, 27 Nov 2023 10:26:59 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id BCGDFfNuZGXofgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:26:59 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 7f76510e-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 17/32] Mini-OS: add EXPORT_SYMBOL() instances to gntmap.c Date: Mon, 27 Nov 2023 11:25:08 +0100 Message-Id: <20231127102523.28003-18-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: +++++++++++++++++++++++++ Authentication-Results: smtp-out1.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out1.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Rspamd-Server: rspamd2 X-Spamd-Result: default: False [25.48 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_FAIL(1.00)[-all]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; BROKEN_CONTENT_TYPE(1.50)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; BAYES_SPAM(3.98)[96.94%]; NEURAL_SPAM_SHORT(3.00)[1.000]; MX_GOOD(-0.01)[]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] X-Rspamd-Queue-Id: 87E5921A5E Add the needed instances of EXPORT_SYMBOL() to gntmap.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- gntmap.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/gntmap.c b/gntmap.c index 3422ab23..5f57d6b3 100644 --- a/gntmap.c +++ b/gntmap.c @@ -106,6 +106,7 @@ gntmap_set_max_grants(struct gntmap *map, int count) map->nentries = count; return 0; } +EXPORT_SYMBOL(gntmap_set_max_grants); static int _gntmap_unmap_grant_ref(struct gntmap *map, int idx) @@ -209,6 +210,7 @@ gntmap_munmap(struct gntmap *map, unsigned long start_address, int count) return 0; } +EXPORT_SYMBOL(gntmap_munmap); void* gntmap_map_grant_refs(struct gntmap *map, @@ -251,6 +253,7 @@ gntmap_map_grant_refs(struct gntmap *map, return (void*) addr; } +EXPORT_SYMBOL(gntmap_map_grant_refs); void gntmap_init(struct gntmap *map) @@ -259,6 +262,7 @@ gntmap_init(struct gntmap *map) map->nentries = 0; map->entries = NULL; } +EXPORT_SYMBOL(gntmap_init); void gntmap_fini(struct gntmap *map) @@ -281,3 +285,4 @@ gntmap_fini(struct gntmap *map) map->entries = NULL; map->nentries = 0; } +EXPORT_SYMBOL(gntmap_fini); From patchwork Mon Nov 27 10:25:09 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469340 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 13F2DC4167B for ; Mon, 27 Nov 2023 10:38:23 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641836.1000779 (Exim 4.92) (envelope-from ) id 1r7Z0F-0006hu-Cx; Mon, 27 Nov 2023 10:38:11 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641836.1000779; Mon, 27 Nov 2023 10:38:11 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z0F-0006hl-AF; Mon, 27 Nov 2023 10:38:11 +0000 Received: by outflank-mailman (input) for mailman id 641836; Mon, 27 Nov 2023 10:38:09 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YpX-0000Co-8A for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:27:07 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 82c2956e-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:27:05 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 1360D21B08; Mon, 27 Nov 2023 10:27:05 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id DDA65132A6; Mon, 27 Nov 2023 10:27:04 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id wEHaNPhuZGX0fgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:27:04 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 82c2956e-8d0f-11ee-98e2-6d05b1d4d9a1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080825; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=90LIXqRuYEhUqlUUdjvXyDMioMTVUvaIxj4Mp4Wj2kc=; b=QV5+kCYudc661PKbdtL8tjQn+f8YBhkFTsFP1xfGGZQz87GjDG8z2zpgl/KK4gdFqN/CKG 6U/wC9bgs3tkGWa7QTQFLG+4NMrSkW1OuCw3xFyhBZVRAZg2SUdPUwVV5J8tcjqVXG7iLb fwO9QO0EqIgZlYCgBdS/L0CDtM9U8zc= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 18/32] Mini-OS: add EXPORT_SYMBOL() instances to gnttab.c Date: Mon, 27 Nov 2023 11:25:09 +0100 Message-Id: <20231127102523.28003-19-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out1.suse.de; none X-Spamd-Result: default: False [16.27 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(4.87)[99.42%]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_SHORT(3.00)[1.000]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to gnttab.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- gnttab.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gnttab.c b/gnttab.c index 6978a9bc..8168ed5d 100644 --- a/gnttab.c +++ b/gnttab.c @@ -80,6 +80,7 @@ gnttab_grant_access(domid_t domid, unsigned long frame, int readonly) return ref; } +EXPORT_SYMBOL(gnttab_grant_access); grant_ref_t gnttab_grant_transfer(domid_t domid, unsigned long pfn) @@ -94,6 +95,7 @@ gnttab_grant_transfer(domid_t domid, unsigned long pfn) return ref; } +EXPORT_SYMBOL(gnttab_grant_transfer); int gnttab_end_access(grant_ref_t ref) @@ -114,6 +116,7 @@ gnttab_end_access(grant_ref_t ref) put_free_entry(ref); return 1; } +EXPORT_SYMBOL(gnttab_end_access); unsigned long gnttab_end_transfer(grant_ref_t ref) @@ -144,6 +147,7 @@ gnttab_end_transfer(grant_ref_t ref) return frame; } +EXPORT_SYMBOL(gnttab_end_transfer); grant_ref_t gnttab_alloc_and_grant(void **map) @@ -156,6 +160,7 @@ gnttab_alloc_and_grant(void **map) gref = gnttab_grant_access(0, mfn, 0); return gref; } +EXPORT_SYMBOL(gnttab_alloc_and_grant); static const char * const gnttabop_error_msgs[] = GNTTABOP_error_msgs; @@ -168,6 +173,7 @@ gnttabop_error(int16_t status) else return gnttabop_error_msgs[status]; } +EXPORT_SYMBOL(gnttabop_error); void init_gnttab(void) From patchwork Mon Nov 27 10:25:10 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469316 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6C811C4167B for ; Mon, 27 Nov 2023 10:27:25 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641747.1000580 (Exim 4.92) (envelope-from ) id 1r7Ypg-0004QE-SF; Mon, 27 Nov 2023 10:27:16 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641747.1000580; Mon, 27 Nov 2023 10:27:16 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Ypg-0004Q7-Oz; Mon, 27 Nov 2023 10:27:16 +0000 Received: by outflank-mailman (input) for mailman id 641747; Mon, 27 Nov 2023 10:27:14 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Ype-0004NR-Rf for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:27:14 +0000 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.223.131]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 861a515c-8d0f-11ee-9b0e-b553b5be7939; Mon, 27 Nov 2023 11:27:11 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 940B7202A5; Mon, 27 Nov 2023 10:27:10 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 6AB62132A6; Mon, 27 Nov 2023 10:27:10 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id qH7JGP5uZGX/fgAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:27:10 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 861a515c-8d0f-11ee-9b0e-b553b5be7939 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 19/32] Mini-OS: add EXPORT_SYMBOL() instances to ioremap.c Date: Mon, 27 Nov 2023 11:25:10 +0100 Message-Id: <20231127102523.28003-20-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: +++++++++++++++ X-Rspamd-Server: rspamd1 X-Rspamd-Queue-Id: 940B7202A5 Authentication-Results: smtp-out2.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out2.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Spamd-Result: default: False [15.00 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_FAIL(1.00)[-all]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; BROKEN_CONTENT_TYPE(1.50)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; RCPT_COUNT_FIVE(0.00)[5]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; BAYES_SPAM(0.16)[64.98%]; MX_GOOD(-0.01)[]; NEURAL_HAM_SHORT(-0.20)[-1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] X-Spam: Yes Add the needed instances of EXPORT_SYMBOL() to ioremap.c. Signed-off-by: Juergen Gross --- V3: - new patch --- arch/x86/ioremap.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/arch/x86/ioremap.c b/arch/x86/ioremap.c index 4384b1c0..fda74d5d 100644 --- a/arch/x86/ioremap.c +++ b/arch/x86/ioremap.c @@ -51,11 +51,13 @@ void *ioremap(unsigned long phys_addr, unsigned long size) { return __do_ioremap(phys_addr, size, IO_PROT); } +EXPORT_SYMBOL(ioremap); void *ioremap_nocache(unsigned long phys_addr, unsigned long size) { return __do_ioremap(phys_addr, size, IO_PROT_NOCACHE); } +EXPORT_SYMBOL(ioremap_nocache); /* Un-map the io-remapped region. Currently no list of existing mappings is * maintained, so the caller has to supply the size */ @@ -69,7 +71,6 @@ void iounmap(void *virt_addr, unsigned long size) unmap_frames(va & PAGE_MASK, num_pages); } - - +EXPORT_SYMBOL(iounmap); /* -*- Mode:C; c-basic-offset:4; tab-width:4 indent-tabs-mode:nil -*- */ From patchwork Mon Nov 27 10:25:11 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469317 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1DA71C0755A for ; Mon, 27 Nov 2023 10:27:32 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641748.1000591 (Exim 4.92) (envelope-from ) id 1r7Ypk-0004h0-4S; Mon, 27 Nov 2023 10:27:20 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641748.1000591; Mon, 27 Nov 2023 10:27:20 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Ypk-0004gr-1a; Mon, 27 Nov 2023 10:27:20 +0000 Received: by outflank-mailman (input) for mailman id 641748; Mon, 27 Nov 2023 10:27:19 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Ypj-0004NR-B9 for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:27:19 +0000 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.223.131]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 89606ddc-8d0f-11ee-9b0e-b553b5be7939; Mon, 27 Nov 2023 11:27:16 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 1EE59202A5; Mon, 27 Nov 2023 10:27:16 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id EAB10132A6; Mon, 27 Nov 2023 10:27:15 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id YFcWOANvZGUDfwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:27:15 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 89606ddc-8d0f-11ee-9b0e-b553b5be7939 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080836; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=vsQt5sczdEkDLsGfMhKbpXQdiEi3uQZXsLLDtTgbDTg=; b=H/K2ZeNdRRhpty2LMEcJiw14lt/9n5XrASb2s1HaK1yR/9x6aF/crZAm1V5A0Z2S4UHr6b 1CZs6jozc3Qw+WG9+eTWj15xdl+9J5VPDgNs9PYzXvvc4zE+7AmeFqK2I9v3qA9KJSejjn 3Hx/MkKyTTPTt/eER/6Wjp4mds8bo+M= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 20/32] Mini-OS: add EXPORT_SYMBOL() instances to lock.c Date: Mon, 27 Nov 2023 11:25:11 +0100 Message-Id: <20231127102523.28003-21-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out2.suse.de; none X-Spamd-Result: default: False [3.80 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(0.10)[61.14%]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_HAM_SHORT(-0.20)[-0.999]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to lock.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- lock.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/lock.c b/lock.c index 61194e5d..8f58344f 100644 --- a/lock.c +++ b/lock.c @@ -17,6 +17,7 @@ int ___lock_init(_LOCK_T *lock) init_waitqueue_head(&lock->wait); return 0; } +EXPORT_SYMBOL(___lock_init); int ___lock_acquire(_LOCK_T *lock) { @@ -32,6 +33,7 @@ int ___lock_acquire(_LOCK_T *lock) local_irq_restore(flags); return 0; } +EXPORT_SYMBOL(___lock_acquire); int ___lock_try_acquire(_LOCK_T *lock) { @@ -45,6 +47,7 @@ int ___lock_try_acquire(_LOCK_T *lock) local_irq_restore(flags); return ret; } +EXPORT_SYMBOL(___lock_try_acquire); int ___lock_release(_LOCK_T *lock) { @@ -55,7 +58,7 @@ int ___lock_release(_LOCK_T *lock) local_irq_restore(flags); return 0; } - +EXPORT_SYMBOL(___lock_release); int ___lock_init_recursive(_LOCK_RECURSIVE_T *lock) { @@ -63,6 +66,7 @@ int ___lock_init_recursive(_LOCK_RECURSIVE_T *lock) init_waitqueue_head(&lock->wait); return 0; } +EXPORT_SYMBOL(___lock_init_recursive); int ___lock_acquire_recursive(_LOCK_RECURSIVE_T *lock) { @@ -81,6 +85,7 @@ int ___lock_acquire_recursive(_LOCK_RECURSIVE_T *lock) lock->count++; return 0; } +EXPORT_SYMBOL(___lock_acquire_recursive); int ___lock_try_acquire_recursive(_LOCK_RECURSIVE_T *lock) { @@ -95,6 +100,7 @@ int ___lock_try_acquire_recursive(_LOCK_RECURSIVE_T *lock) local_irq_restore(flags); return ret; } +EXPORT_SYMBOL(___lock_try_acquire_recursive); int ___lock_release_recursive(_LOCK_RECURSIVE_T *lock) { @@ -108,5 +114,6 @@ int ___lock_release_recursive(_LOCK_RECURSIVE_T *lock) local_irq_restore(flags); return 0; } +EXPORT_SYMBOL(___lock_release_recursive); #endif From patchwork Mon Nov 27 10:25:12 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469318 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 83EFCC4167B for ; Mon, 27 Nov 2023 10:27:34 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641751.1000609 (Exim 4.92) (envelope-from ) id 1r7Ypr-00058o-HP; Mon, 27 Nov 2023 10:27:27 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641751.1000609; Mon, 27 Nov 2023 10:27:27 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Ypr-00058f-DU; Mon, 27 Nov 2023 10:27:27 +0000 Received: by outflank-mailman (input) for mailman id 641751; Mon, 27 Nov 2023 10:27:26 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Ypp-0004NR-Vy for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:27:25 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 8cbd7c38-8d0f-11ee-9b0e-b553b5be7939; Mon, 27 Nov 2023 11:27:22 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 9E72921B08; Mon, 27 Nov 2023 10:27:21 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 752E5132A6; Mon, 27 Nov 2023 10:27:21 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id kB5gGwlvZGUKfwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:27:21 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 8cbd7c38-8d0f-11ee-9b0e-b553b5be7939 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 21/32] Mini-OS: add EXPORT_SYMBOL() instances to time.c Date: Mon, 27 Nov 2023 11:25:12 +0100 Message-Id: <20231127102523.28003-22-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: ++++++++++++++++++++++ Authentication-Results: smtp-out1.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out1.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Rspamd-Server: rspamd2 X-Spamd-Result: default: False [22.60 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_FAIL(1.00)[-all]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_SHORT(3.00)[1.000]; BROKEN_CONTENT_TYPE(1.50)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; BAYES_SPAM(1.10)[82.54%]; MX_GOOD(-0.01)[]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] X-Rspamd-Queue-Id: 9E72921B08 Add the needed instances of EXPORT_SYMBOL() to time.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- arch/arm/time.c | 1 + arch/x86/time.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/arm/time.c b/arch/arm/time.c index a088981e..3483511a 100644 --- a/arch/arm/time.c +++ b/arch/arm/time.c @@ -83,6 +83,7 @@ int gettimeofday(struct timeval *tv, void *tz) return 0; } +EXPORT_SYMBOL(gettimeofday); /* Set the timer and mask. */ void write_timer_ctl(uint32_t value) { diff --git a/arch/x86/time.c b/arch/x86/time.c index 8077c80c..332c0260 100644 --- a/arch/x86/time.c +++ b/arch/x86/time.c @@ -204,7 +204,7 @@ int gettimeofday(struct timeval *tv, void *tz) return 0; } - +EXPORT_SYMBOL(gettimeofday); void block_domain(s_time_t until) { From patchwork Mon Nov 27 10:25:13 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469350 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 365B7C4167B for ; Mon, 27 Nov 2023 10:40:27 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641908.1000927 (Exim 4.92) (envelope-from ) id 1r7Z2K-0005bO-AM; Mon, 27 Nov 2023 10:40:20 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641908.1000927; Mon, 27 Nov 2023 10:40:20 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z2K-0005ab-6p; Mon, 27 Nov 2023 10:40:20 +0000 Received: by outflank-mailman (input) for mailman id 641908; Mon, 27 Nov 2023 10:40:19 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yps-0000Co-TB for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:27:28 +0000 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.223.131]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 900feff4-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:27:28 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 2CB5C202A8; Mon, 27 Nov 2023 10:27:27 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 01A33132A6; Mon, 27 Nov 2023 10:27:26 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id rjPDOg5vZGUQfwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:27:26 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 900feff4-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 22/32] Mini-OS: add EXPORT_SYMBOL() instances to lwip-*.c Date: Mon, 27 Nov 2023 11:25:13 +0100 Message-Id: <20231127102523.28003-23-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: +++++++++++++++ X-Rspamd-Server: rspamd1 X-Rspamd-Queue-Id: 2CB5C202A8 Authentication-Results: smtp-out2.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out2.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Spamd-Result: default: False [15.00 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_FAIL(1.00)[-all]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; BROKEN_CONTENT_TYPE(1.50)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; RCPT_COUNT_FIVE(0.00)[5]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; BAYES_SPAM(1.04)[81.94%]; MX_GOOD(-0.01)[]; NEURAL_HAM_SHORT(-0.20)[-1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] X-Spam: Yes Add the needed instances of EXPORT_SYMBOL() to lwip-*.c. Most added symbols are in LWIP, but we can't add the EXPORT_SYMBOL() instances easily there. Signed-off-by: Juergen Gross --- V3: - new patch --- lwip-arch.c | 9 +++++++++ lwip-net.c | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/lwip-arch.c b/lwip-arch.c index 21e941e9..7907f446 100644 --- a/lwip-arch.c +++ b/lwip-arch.c @@ -12,7 +12,9 @@ #include #include #include +#include #include +#include /* Is called to initialize the sys_arch layer */ void sys_init(void) @@ -293,3 +295,10 @@ void lwip_die(char *fmt, ...) printk("\n"); BUG(); } + +EXPORT_SYMBOL(htonl); +EXPORT_SYMBOL(htons); +EXPORT_SYMBOL(inet_aton); +EXPORT_SYMBOL(inet_ntoa); +EXPORT_SYMBOL(ntohl); +EXPORT_SYMBOL(ntohs); diff --git a/lwip-net.c b/lwip-net.c index 16950d32..e71a11c7 100644 --- a/lwip-net.c +++ b/lwip-net.c @@ -250,7 +250,7 @@ void networking_set_addr(struct ip_addr *ipaddr, struct ip_addr *netmask, struct netif_set_netmask(the_interface, netmask); netif_set_gw(the_interface, gw); } - +EXPORT_SYMBOL(networking_set_addr); static void arp_timer(void *arg) From patchwork Mon Nov 27 10:25:14 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469349 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 26A25C4167B for ; Mon, 27 Nov 2023 10:40:11 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641900.1000908 (Exim 4.92) (envelope-from ) id 1r7Z24-0004G9-M9; Mon, 27 Nov 2023 10:40:04 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641900.1000908; Mon, 27 Nov 2023 10:40:04 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z24-0004Fp-Hj; Mon, 27 Nov 2023 10:40:04 +0000 Received: by outflank-mailman (input) for mailman id 641900; Mon, 27 Nov 2023 10:40:02 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Ypz-0000Co-Gm for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:27:35 +0000 Received: from smtp-out2.suse.de (smtp-out2.suse.de [2a07:de40:b251:101:10:150:64:2]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 93398bcc-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:27:33 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id AB9C320214; Mon, 27 Nov 2023 10:27:32 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 82EF1132A6; Mon, 27 Nov 2023 10:27:32 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id UH62HhRvZGUYfwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:27:32 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 93398bcc-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 23/32] Mini-OS: add EXPORT_SYMBOL() instances to 9pfront.c Date: Mon, 27 Nov 2023 11:25:14 +0100 Message-Id: <20231127102523.28003-24-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: ++++++++++++++++++ X-Rspamd-Server: rspamd1 X-Rspamd-Queue-Id: AB9C320214 Authentication-Results: smtp-out2.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out2.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Spamd-Result: default: False [18.44 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_FAIL(1.00)[-all]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; BROKEN_CONTENT_TYPE(1.50)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; RCPT_COUNT_FIVE(0.00)[5]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; BAYES_SPAM(4.64)[98.82%]; MX_GOOD(-0.01)[]; NEURAL_HAM_SHORT(-0.20)[-1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to 9pfront.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- 9pfront.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/9pfront.c b/9pfront.c index 35c5552b..315089bc 100644 --- a/9pfront.c +++ b/9pfront.c @@ -1243,6 +1243,7 @@ void *init_9pfront(unsigned int id, const char *mnt) free(msg); return NULL; } +EXPORT_SYMBOL(init_9pfront); void shutdown_9pfront(void *dev) { @@ -1286,6 +1287,7 @@ void shutdown_9pfront(void *dev) printk("9pfsfront shutdown %u failed, %s\n", dev9p->id, reason); free(msg); } +EXPORT_SYMBOL(shutdown_9pfront); static const struct file_ops ops_9pfs = { .name = "9pfs", From patchwork Mon Nov 27 10:25:15 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469319 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 775CFC4167B for ; Mon, 27 Nov 2023 10:27:55 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641757.1000619 (Exim 4.92) (envelope-from ) id 1r7Yq6-0005rJ-NJ; Mon, 27 Nov 2023 10:27:42 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641757.1000619; Mon, 27 Nov 2023 10:27:42 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yq6-0005r7-Kb; Mon, 27 Nov 2023 10:27:42 +0000 Received: by outflank-mailman (input) for mailman id 641757; Mon, 27 Nov 2023 10:27:41 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yq5-0004NR-Fy for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:27:41 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 968569d8-8d0f-11ee-9b0e-b553b5be7939; Mon, 27 Nov 2023 11:27:38 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 33AB221B08; Mon, 27 Nov 2023 10:27:38 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 0AC51132A6; Mon, 27 Nov 2023 10:27:38 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id RWhXARpvZGUefwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:27:38 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 968569d8-8d0f-11ee-9b0e-b553b5be7939 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 24/32] Mini-OS: add EXPORT_SYMBOL() instances to blkfront.c Date: Mon, 27 Nov 2023 11:25:15 +0100 Message-Id: <20231127102523.28003-25-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: +++++++++++++++++++++ Authentication-Results: smtp-out1.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out1.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Rspamd-Server: rspamd2 X-Spamd-Result: default: False [21.80 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(0.30)[70.31%]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; MX_GOOD(-0.01)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; ARC_NA(0.00)[]; R_SPF_FAIL(1.00)[-all]; FROM_HAS_DN(0.00)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(3.00)[1.000]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; RCVD_TLS_ALL(0.00)[] X-Rspamd-Queue-Id: 33AB221B08 Add the needed instances of EXPORT_SYMBOL() to blkfront.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- blkfront.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/blkfront.c b/blkfront.c index 8f140896..b0fc80d1 100644 --- a/blkfront.c +++ b/blkfront.c @@ -23,9 +23,7 @@ /* Note: we really suppose non-preemptive threads. */ DECLARE_WAIT_QUEUE_HEAD(blkfront_queue); - - - +EXPORT_SYMBOL(blkfront_queue); #define BLK_RING_SIZE __RING_SIZE((struct blkif_sring *)0, PAGE_SIZE) #define GRANT_INVALID_REF 0 @@ -243,6 +241,7 @@ error: free_blkfront(dev); return NULL; } +EXPORT_SYMBOL(init_blkfront); void shutdown_blkfront(struct blkfront_dev *dev) { @@ -304,6 +303,7 @@ close: if (!err) free_blkfront(dev); } +EXPORT_SYMBOL(shutdown_blkfront); static void blkfront_wait_slot(struct blkfront_dev *dev) { @@ -386,6 +386,7 @@ void blkfront_aio(struct blkfront_aiocb *aiocbp, int write) if(notify) notify_remote_via_evtchn(dev->evtchn); } +EXPORT_SYMBOL(blkfront_aio); static void blkfront_aio_cb(struct blkfront_aiocb *aiocbp, int ret) { @@ -417,6 +418,7 @@ void blkfront_io(struct blkfront_aiocb *aiocbp, int write) remove_waiter(w, blkfront_queue); local_irq_restore(flags); } +EXPORT_SYMBOL(blkfront_io); static void blkfront_push_operation(struct blkfront_dev *dev, uint8_t op, uint64_t id) { @@ -444,6 +446,7 @@ void blkfront_aio_push_operation(struct blkfront_aiocb *aiocbp, uint8_t op) struct blkfront_dev *dev = aiocbp->aio_dev; blkfront_push_operation(dev, op, (uintptr_t) aiocbp); } +EXPORT_SYMBOL(blkfront_aio_push_operation); void blkfront_sync(struct blkfront_dev *dev) { @@ -473,6 +476,7 @@ void blkfront_sync(struct blkfront_dev *dev) remove_waiter(w, blkfront_queue); local_irq_restore(flags); } +EXPORT_SYMBOL(blkfront_sync); int blkfront_aio_poll(struct blkfront_dev *dev) { @@ -557,6 +561,7 @@ moretodo: return nr_consumed; } +EXPORT_SYMBOL(blkfront_aio_poll); #ifdef HAVE_LIBC static int blkfront_posix_rwop(struct file *file, uint8_t *buf, size_t count, @@ -773,4 +778,5 @@ int blkfront_open(struct blkfront_dev *dev) return dev->fd; } +EXPORT_SYMBOL(blkfront_open); #endif From patchwork Mon Nov 27 10:25:16 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469330 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id BD132C4167B for ; Mon, 27 Nov 2023 10:36:21 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641781.1000668 (Exim 4.92) (envelope-from ) id 1r7YyG-0000bw-PP; Mon, 27 Nov 2023 10:36:08 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641781.1000668; Mon, 27 Nov 2023 10:36:08 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YyG-0000aj-Fv; Mon, 27 Nov 2023 10:36:08 +0000 Received: by outflank-mailman (input) for mailman id 641781; Mon, 27 Nov 2023 10:36:07 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YqA-0000Co-0Y for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:27:46 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 99cccf65-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:27:44 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id B2EE421B08; Mon, 27 Nov 2023 10:27:43 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 8A4A1132A6; Mon, 27 Nov 2023 10:27:43 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id hYaCIB9vZGUmfwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:27:43 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 99cccf65-8d0f-11ee-98e2-6d05b1d4d9a1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080863; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=A7Ph8EWiRNQhlaHcJX8OV0y/unaxE1ONICuU8ZiL5cc=; b=GclHgrD36WDf97KrAwi5GUh8+rXIDW/NWEeCTFfbEVlXi9uJPdb14UyOOY93daE0qnEgvA 2s6hh+mVx8fKEMk5opg6E+wxo3N/C91GI3HGGjLz+M/i3LN6OENUOwIr4CR8hkdtDFxoHo +sDupZHiSMZCEGxNlcqH5nrrpy/Ku8E= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 25/32] Mini-OS: add EXPORT_SYMBOL() instances to fbfront.c Date: Mon, 27 Nov 2023 11:25:16 +0100 Message-Id: <20231127102523.28003-26-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out1.suse.de; none X-Spamd-Result: default: False [12.14 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(0.74)[78.58%]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(3.00)[1.000]; MIME_GOOD(-0.10)[text/plain]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to fbfront.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- fbfront.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/fbfront.c b/fbfront.c index 1b67f527..d4e28d0c 100644 --- a/fbfront.c +++ b/fbfront.c @@ -201,6 +201,7 @@ error: free_kbdfront(dev); return NULL; } +EXPORT_SYMBOL(init_kbdfront); int kbdfront_receive(struct kbdfront_dev *dev, union xenkbd_in_event *buf, int n) { @@ -239,7 +240,7 @@ int kbdfront_receive(struct kbdfront_dev *dev, union xenkbd_in_event *buf, int n return i; } - +EXPORT_SYMBOL(kbdfront_receive); void shutdown_kbdfront(struct kbdfront_dev *dev) { @@ -301,6 +302,7 @@ close_kbdfront: if (!err) free_kbdfront(dev); } +EXPORT_SYMBOL(shutdown_kbdfront); #ifdef HAVE_LIBC static int kbd_read(struct file *file, void *buf, size_t nbytes) @@ -351,6 +353,7 @@ int kbdfront_open(struct kbdfront_dev *dev) return dev->fd; } +EXPORT_SYMBOL(kbdfront_open); #endif @@ -451,6 +454,7 @@ int fbfront_receive(struct fbfront_dev *dev, union xenfb_in_event *buf, int n) return i; } +EXPORT_SYMBOL(fbfront_receive); struct fbfront_dev *init_fbfront(char *_nodename, unsigned long *mfns, int width, int height, int depth, int stride, int n) { @@ -617,6 +621,7 @@ error: free_fbfront(dev); return NULL; } +EXPORT_SYMBOL(init_fbfront); static void fbfront_out_event(struct fbfront_dev *dev, union xenfb_out_event *event) { @@ -668,6 +673,7 @@ void fbfront_update(struct fbfront_dev *dev, int x, int y, int width, int height update.height = height; fbfront_out_event(dev, (union xenfb_out_event *) &update); } +EXPORT_SYMBOL(fbfront_update); void fbfront_resize(struct fbfront_dev *dev, int width, int height, int stride, int depth, int offset) { @@ -681,6 +687,7 @@ void fbfront_resize(struct fbfront_dev *dev, int width, int height, int stride, dev->offset = resize.offset = offset; fbfront_out_event(dev, (union xenfb_out_event *) &resize); } +EXPORT_SYMBOL(fbfront_resize); void shutdown_fbfront(struct fbfront_dev *dev) { @@ -745,6 +752,7 @@ close_fbfront: if (!err) free_fbfront(dev); } +EXPORT_SYMBOL(shutdown_fbfront); #ifdef HAVE_LIBC static int fbfront_read(struct file *file, void *buf, size_t nbytes) @@ -794,5 +802,6 @@ int fbfront_open(struct fbfront_dev *dev) file->dev = dev; return dev->fd; } +EXPORT_SYMBOL(fbfront_open); #endif From patchwork Mon Nov 27 10:25:17 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469341 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 0708DC0755A for ; Mon, 27 Nov 2023 10:38:24 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641837.1000788 (Exim 4.92) (envelope-from ) id 1r7Z0K-00070G-KB; Mon, 27 Nov 2023 10:38:16 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641837.1000788; Mon, 27 Nov 2023 10:38:16 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z0K-000707-HH; Mon, 27 Nov 2023 10:38:16 +0000 Received: by outflank-mailman (input) for mailman id 641837; Mon, 27 Nov 2023 10:38:14 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YqE-0000Co-Oj for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:27:50 +0000 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.223.131]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id 9d1e6be3-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:27:50 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 4352220214; Mon, 27 Nov 2023 10:27:49 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 18344132A6; Mon, 27 Nov 2023 10:27:49 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id TMKfBCVvZGUqfwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:27:49 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 9d1e6be3-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 26/32] Mini-OS: add EXPORT_SYMBOL() instances to netfront.c Date: Mon, 27 Nov 2023 11:25:17 +0100 Message-Id: <20231127102523.28003-27-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: +++++++++++++++ X-Rspamd-Server: rspamd1 X-Rspamd-Queue-Id: 4352220214 Authentication-Results: smtp-out2.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out2.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Spamd-Result: default: False [15.00 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(0.15)[64.57%]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; MX_GOOD(-0.01)[]; NEURAL_HAM_SHORT(-0.20)[-1.000]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; ARC_NA(0.00)[]; R_SPF_FAIL(1.00)[-all]; FROM_HAS_DN(0.00)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; MIME_GOOD(-0.10)[text/plain]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; RCVD_TLS_ALL(0.00)[] X-Spam: Yes Add the needed instances of EXPORT_SYMBOL() to netfront.c. Signed-off-by: Juergen Gross --- V3: - new patch --- netfront.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/netfront.c b/netfront.c index 164fdc66..7de2498a 100644 --- a/netfront.c +++ b/netfront.c @@ -370,16 +370,19 @@ out: err: return dev; } +EXPORT_SYMBOL(init_netfront); char *netfront_get_netmask(struct netfront_dev *dev) { return dev->mask ? strdup(dev->mask) : NULL; } +EXPORT_SYMBOL(netfront_get_netmask); char *netfront_get_gateway(struct netfront_dev *dev) { return dev->gw ? strdup(dev->gw) : NULL; } +EXPORT_SYMBOL(netfront_get_gateway); static struct netfront_dev *_init_netfront(struct netfront_dev *dev) { @@ -625,6 +628,7 @@ int netfront_tap_open(char *nodename) { file->dev = dev; return dev->fd; } +EXPORT_SYMBOL(netfront_tap_open); #endif void shutdown_netfront(struct netfront_dev *dev) @@ -654,6 +658,7 @@ void shutdown_netfront(struct netfront_dev *dev) free_netfront(dev); } } +EXPORT_SYMBOL(shutdown_netfront); static int _shutdown_netfront(struct netfront_dev *dev) { @@ -813,6 +818,7 @@ void netfront_xmit(struct netfront_dev *dev, const unsigned char *data, int len) network_tx_buf_gc(dev); local_irq_restore(flags); } +EXPORT_SYMBOL(netfront_xmit); #ifdef HAVE_LIBC ssize_t netfront_receive(struct netfront_dev *dev, unsigned char *data, size_t len) @@ -840,6 +846,7 @@ ssize_t netfront_receive(struct netfront_dev *dev, unsigned char *data, size_t l return dev->rlen; } +EXPORT_SYMBOL(netfront_receive); #endif void netfront_set_rx_handler(struct netfront_dev *dev, From patchwork Mon Nov 27 10:25:18 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469351 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1E9E6C4167B for ; Mon, 27 Nov 2023 10:40:36 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641906.1000922 (Exim 4.92) (envelope-from ) id 1r7Z2K-0005XS-1T; Mon, 27 Nov 2023 10:40:20 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641906.1000922; Mon, 27 Nov 2023 10:40:19 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z2J-0005Wx-Sn; Mon, 27 Nov 2023 10:40:19 +0000 Received: by outflank-mailman (input) for mailman id 641906; Mon, 27 Nov 2023 10:40:19 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YqM-0004NR-OZ for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:27:58 +0000 Received: from smtp-out2.suse.de (smtp-out2.suse.de [2a07:de40:b251:101:10:150:64:2]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id a06271ea-8d0f-11ee-9b0e-b553b5be7939; Mon, 27 Nov 2023 11:27:55 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id C6769202A8; Mon, 27 Nov 2023 10:27:54 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 9B9D7132A6; Mon, 27 Nov 2023 10:27:54 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id rj2uJCpvZGUufwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:27:54 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: a06271ea-8d0f-11ee-9b0e-b553b5be7939 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080874; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=S8H+CSjoaNbzZijd2tLFpL6ZuHjupFKRJ6T0BDc7jy0=; b=MiraO6Du6oOChuFu+ZcXdUcPdlEOAGriPvPSPXUfvExiIuM/sn4XO6OLzDuvIMvf+WBdBe BGgvuGn+bIff4xKUUEbfwG7GOzOLGZpz8JNvdL64ZgOdso+6scg9o4Pvpxq8nLfQwzhTei eG2jnOld468dRzseHQIgLRsFjINuRzU= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 27/32] Mini-OS: add EXPORT_SYMBOL() instances to pcifront.c Date: Mon, 27 Nov 2023 11:25:18 +0100 Message-Id: <20231127102523.28003-28-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out2.suse.de; none X-Spamd-Result: default: False [3.76 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(0.06)[57.24%]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_HAM_SHORT(-0.20)[-0.999]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to pcifront.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- pcifront.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/pcifront.c b/pcifront.c index 56423562..f1d69396 100644 --- a/pcifront.c +++ b/pcifront.c @@ -278,6 +278,7 @@ error: free_pcifront(dev); return NULL; } +EXPORT_SYMBOL(init_pcifront); void pcifront_scan(struct pcifront_dev *dev, void (*func)(unsigned int domain, unsigned int bus, unsigned slot, unsigned int fun)) { @@ -319,6 +320,7 @@ void pcifront_scan(struct pcifront_dev *dev, void (*func)(unsigned int domain, u } free(path); } +EXPORT_SYMBOL(pcifront_scan); void shutdown_pcifront(struct pcifront_dev *dev) { @@ -377,6 +379,7 @@ close_pcifront: if (!err) free_pcifront(dev); } +EXPORT_SYMBOL(shutdown_pcifront); int pcifront_physical_to_virtual (struct pcifront_dev *dev, unsigned int *dom, @@ -451,6 +454,7 @@ void pcifront_op(struct pcifront_dev *dev, struct xen_pci_op *op) rmb(); *op = dev->info->op; } +EXPORT_SYMBOL(pcifront_op); int pcifront_conf_read(struct pcifront_dev *dev, unsigned int dom, @@ -481,6 +485,7 @@ int pcifront_conf_read(struct pcifront_dev *dev, return 0; } +EXPORT_SYMBOL(pcifront_conf_read); int pcifront_conf_write(struct pcifront_dev *dev, unsigned int dom, @@ -508,6 +513,7 @@ int pcifront_conf_write(struct pcifront_dev *dev, return op.err; } +EXPORT_SYMBOL(pcifront_conf_write); int pcifront_enable_msi(struct pcifront_dev *dev, unsigned int dom, @@ -533,6 +539,7 @@ int pcifront_enable_msi(struct pcifront_dev *dev, else return op.value; } +EXPORT_SYMBOL(pcifront_enable_msi); int pcifront_disable_msi(struct pcifront_dev *dev, unsigned int dom, @@ -555,6 +562,7 @@ int pcifront_disable_msi(struct pcifront_dev *dev, return op.err; } +EXPORT_SYMBOL(pcifront_disable_msi); int pcifront_enable_msix(struct pcifront_dev *dev, unsigned int dom, @@ -589,7 +597,7 @@ int pcifront_enable_msix(struct pcifront_dev *dev, return 0; } - +EXPORT_SYMBOL(pcifront_enable_msix); int pcifront_disable_msix(struct pcifront_dev *dev, unsigned int dom, @@ -612,3 +620,4 @@ int pcifront_disable_msix(struct pcifront_dev *dev, return op.err; } +EXPORT_SYMBOL(pcifront_disable_msix); From patchwork Mon Nov 27 10:25:19 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469352 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 11F81C4167B for ; Mon, 27 Nov 2023 10:40:47 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641915.1000961 (Exim 4.92) (envelope-from ) id 1r7Z2d-00077m-4J; Mon, 27 Nov 2023 10:40:39 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641915.1000961; Mon, 27 Nov 2023 10:40:39 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z2d-00077d-1A; Mon, 27 Nov 2023 10:40:39 +0000 Received: by outflank-mailman (input) for mailman id 641915; Mon, 27 Nov 2023 10:40:38 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YqS-0004NR-8Q for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:28:04 +0000 Received: from smtp-out2.suse.de (smtp-out2.suse.de [2a07:de40:b251:101:10:150:64:2]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id a3ac04e8-8d0f-11ee-9b0e-b553b5be7939; Mon, 27 Nov 2023 11:28:00 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 4B50E202A8; Mon, 27 Nov 2023 10:28:00 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 2281C132A6; Mon, 27 Nov 2023 10:28:00 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id OMI+BzBvZGU5fwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:28:00 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: a3ac04e8-8d0f-11ee-9b0e-b553b5be7939 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080880; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ycr4nnyHBdDBvJ+GYl2PkdDbUSfnWvY3qJvRrp1NPfg=; b=vBupVY1PuNl1EfwC9Apaf9wlKHRObRIQCO3YZhGXiqzByrlf5kNtMSkZJHMnqOv9qEIV+Q mr68zz+1opApUf/rSqpkVoIKviQhIPxRjjy/iePlFVxlcbnOQb0hvR3u5nVlr8H6jc6QKX 7ZmuWdAEujUFYX4cw8FrSottaKdzqvU= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 28/32] Mini-OS: add EXPORT_SYMBOL() instances to tpmback.c Date: Mon, 27 Nov 2023 11:25:19 +0100 Message-Id: <20231127102523.28003-29-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out2.suse.de; none X-Spamd-Result: default: False [4.82 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(1.12)[82.74%]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_HAM_SHORT(-0.20)[-0.999]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to tpmback.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- tpmback.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/tpmback.c b/tpmback.c index 22adbd32..ab0df127 100644 --- a/tpmback.c +++ b/tpmback.c @@ -804,6 +804,7 @@ void* tpmback_get_opaque(domid_t domid, unsigned int handle) return tpmif->opaque; } +EXPORT_SYMBOL(tpmback_get_opaque); int tpmback_set_opaque(domid_t domid, unsigned int handle, void *opaque) { @@ -816,6 +817,7 @@ int tpmback_set_opaque(domid_t domid, unsigned int handle, void *opaque) tpmif->opaque = opaque; return 0; } +EXPORT_SYMBOL(tpmback_set_opaque); unsigned char* tpmback_get_uuid(domid_t domid, unsigned int handle) { @@ -827,6 +829,7 @@ unsigned char* tpmback_get_uuid(domid_t domid, unsigned int handle) return tpmif->uuid; } +EXPORT_SYMBOL(tpmback_get_uuid); int tpmback_get_peercontext(domid_t domid, unsigned int handle, void* buffer, int buflen) { @@ -838,6 +841,7 @@ int tpmback_get_peercontext(domid_t domid, unsigned int handle, void* buffer, in return evtchn_get_peercontext(tpmif->evtchn, buffer, buflen); } +EXPORT_SYMBOL(tpmback_get_peercontext); static void event_listener(void) { @@ -903,6 +907,7 @@ void init_tpmback(void (*open_cb)(domid_t, unsigned int), void (*close_cb)(domid eventthread = create_thread("tpmback-listener", event_thread, NULL); } +EXPORT_SYMBOL(init_tpmback); void shutdown_tpmback(void) { @@ -923,6 +928,7 @@ void shutdown_tpmback(void) wake_up(&waitq); schedule(); } +EXPORT_SYMBOL(shutdown_tpmback); static void init_tpmcmd(tpmcmd_t* tpmcmd, domid_t domid, unsigned int handle, void *opaque) { @@ -1061,6 +1067,7 @@ tpmcmd_t* tpmback_req_any(void) TPMBACK_ERR("backend request ready flag was set but no interfaces were actually ready\n"); return NULL; } +EXPORT_SYMBOL(tpmback_req_any); tpmcmd_t* tpmback_req(domid_t domid, unsigned int handle) { @@ -1081,6 +1088,7 @@ tpmcmd_t* tpmback_req(domid_t domid, unsigned int handle) return get_request(tpmif); } +EXPORT_SYMBOL(tpmback_req); void tpmback_resp(tpmcmd_t* tpmcmd) { @@ -1108,6 +1116,7 @@ end: free(tpmcmd); return; } +EXPORT_SYMBOL(tpmback_resp); int tpmback_wait_for_frontend_connect(domid_t *domid, unsigned int *handle) { @@ -1125,8 +1134,10 @@ int tpmback_wait_for_frontend_connect(domid_t *domid, unsigned int *handle) return 0; } +EXPORT_SYMBOL(tpmback_wait_for_frontend_connect); int tpmback_num_frontends(void) { return gtpmdev.num_tpms; } +EXPORT_SYMBOL(tpmback_num_frontends); From patchwork Mon Nov 27 10:25:20 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469344 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 6EE8EC4167B for ; Mon, 27 Nov 2023 10:39:09 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641863.1000843 (Exim 4.92) (envelope-from ) id 1r7Z10-0000ig-SN; Mon, 27 Nov 2023 10:38:58 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641863.1000843; Mon, 27 Nov 2023 10:38:58 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z10-0000iK-LQ; Mon, 27 Nov 2023 10:38:58 +0000 Received: by outflank-mailman (input) for mailman id 641863; Mon, 27 Nov 2023 10:38:57 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7YqX-0004NR-TR for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:28:09 +0000 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.223.131]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id a6fb56be-8d0f-11ee-9b0e-b553b5be7939; Mon, 27 Nov 2023 11:28:06 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id CC569202A8; Mon, 27 Nov 2023 10:28:05 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id A3661132A6; Mon, 27 Nov 2023 10:28:05 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id Ui6jJjVvZGVEfwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:28:05 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: a6fb56be-8d0f-11ee-9b0e-b553b5be7939 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080885; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=3OavG29JmnpyUi3SYYO0kR9XpCfsrefzwj7xVlfdRZw=; b=jsKbaDSg7iI0hkJ0JnsT2e+XZMwrO6az3BvsxsrC8+UbWN6lNKl88tSCDJcPXI3scLe4eH 9JOIdASO3HAh6AGHPD/Uk7LqApT5To243QiyYafYDyvD6gsjfoSFH7RsQj5HeikyPalGFL eUKiyVIR0iNMjgMqOgaSFP5vqx0vl6Q= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 29/32] Mini-OS: add EXPORT_SYMBOL() instances to tpmfront.c Date: Mon, 27 Nov 2023 11:25:20 +0100 Message-Id: <20231127102523.28003-30-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out2.suse.de; none X-Spamd-Result: default: False [4.69 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(0.99)[81.49%]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_HAM_SHORT(-0.20)[-0.999]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to tpmfront.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- tpmfront.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tpmfront.c b/tpmfront.c index f4864d61..83768d07 100644 --- a/tpmfront.c +++ b/tpmfront.c @@ -338,6 +338,8 @@ error: shutdown_tpmfront(dev); return NULL; } +EXPORT_SYMBOL(init_tpmfront); + void shutdown_tpmfront(struct tpmfront_dev* dev) { char* err; @@ -402,6 +404,7 @@ void shutdown_tpmfront(struct tpmfront_dev* dev) } free(dev); } +EXPORT_SYMBOL(shutdown_tpmfront); int tpmfront_send(struct tpmfront_dev* dev, const uint8_t* msg, size_t length) { @@ -528,6 +531,7 @@ int tpmfront_cmd(struct tpmfront_dev* dev, uint8_t* req, size_t reqlen, uint8_t* return 0; } +EXPORT_SYMBOL(tpmfront_cmd); int tpmfront_set_locality(struct tpmfront_dev* dev, int locality) { @@ -536,6 +540,7 @@ int tpmfront_set_locality(struct tpmfront_dev* dev, int locality) dev->page->locality = locality; return 0; } +EXPORT_SYMBOL(tpmfront_set_locality); #ifdef HAVE_LIBC #include @@ -663,5 +668,6 @@ int tpmfront_open(struct tpmfront_dev *dev) return dev->fd; } +EXPORT_SYMBOL(tpmfront_open); #endif From patchwork Mon Nov 27 10:25:21 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469328 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 371A7C4167B for ; Mon, 27 Nov 2023 10:36:00 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641771.1000632 (Exim 4.92) (envelope-from ) id 1r7Yxu-0007vN-FO; Mon, 27 Nov 2023 10:35:46 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641771.1000632; Mon, 27 Nov 2023 10:35:46 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yxu-0007vG-Cu; Mon, 27 Nov 2023 10:35:46 +0000 Received: by outflank-mailman (input) for mailman id 641771; Mon, 27 Nov 2023 10:35:45 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yqa-0000Co-JG for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:28:12 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id aa4770a9-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:28:12 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 5495621BFD; Mon, 27 Nov 2023 10:28:11 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 2AD2F132A6; Mon, 27 Nov 2023 10:28:11 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id 2swsCTtvZGVNfwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:28:11 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: aa4770a9-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 30/32] Mini-OS: add EXPORT_SYMBOL() instances to tpm_tis.c Date: Mon, 27 Nov 2023 11:25:21 +0100 Message-Id: <20231127102523.28003-31-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: +++++++++++++++ X-Rspamd-Server: rspamd1 X-Rspamd-Queue-Id: 5495621BFD Authentication-Results: smtp-out1.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out1.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Spamd-Result: default: False [15.33 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_SPF_FAIL(1.00)[-all]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; BROKEN_CONTENT_TYPE(1.50)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; RCPT_COUNT_FIVE(0.00)[5]; NEURAL_HAM_LONG(-1.00)[-1.000]; RCVD_COUNT_THREE(0.00)[3]; BAYES_SPAM(1.53)[86.00%]; MX_GOOD(-0.01)[]; NEURAL_HAM_SHORT(-0.20)[-1.000]; MID_CONTAINS_FROM(1.00)[]; DBL_BLOCKED_OPENRESOLVER(0.00)[suse.com:email]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] X-Spam: Yes Add the needed instances of EXPORT_SYMBOL() to tpm_tis.c. Signed-off-by: Juergen Gross --- V3: - new patch --- tpm_tis.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tpm_tis.c b/tpm_tis.c index c3998f2d..ad95e289 100644 --- a/tpm_tis.c +++ b/tpm_tis.c @@ -673,6 +673,7 @@ int tpm_tis_request_locality(struct tpm_chip* tpm, int l) { printk("REQ LOCALITY FAILURE\n"); return -1; } +EXPORT_SYMBOL(tpm_tis_request_locality); static uint8_t tpm_tis_status(struct tpm_chip* tpm) { return ioread8(TPM_STS(tpm, tpm->locality)); @@ -1264,6 +1265,7 @@ abort_egress: } return NULL; } +EXPORT_SYMBOL(init_tpm_tis); int tpm_tis_cmd(struct tpm_chip* tpm, uint8_t* req, size_t reqlen, uint8_t** resp, size_t* resplen) { @@ -1281,6 +1283,7 @@ int tpm_tis_cmd(struct tpm_chip* tpm, uint8_t* req, size_t reqlen, uint8_t** res memcpy(*resp, tpm->data_buffer, *resplen); return 0; } +EXPORT_SYMBOL(tpm_tis_cmd); #ifdef HAVE_LIBC #include @@ -1392,6 +1395,7 @@ int tpm_tis_open(struct tpm_chip *tpm) return tpm->fd; } +EXPORT_SYMBOL(tpm_tis_open); /* TPM 2.0 */ @@ -1550,4 +1554,5 @@ abort_egress: } return NULL; } +EXPORT_SYMBOL(init_tpm2_tis); #endif From patchwork Mon Nov 27 10:25:22 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469346 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CA26BC0755A for ; Mon, 27 Nov 2023 10:39:55 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641885.1000865 (Exim 4.92) (envelope-from ) id 1r7Z1h-0001uh-H0; Mon, 27 Nov 2023 10:39:41 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641885.1000865; Mon, 27 Nov 2023 10:39:41 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z1h-0001uE-Bg; Mon, 27 Nov 2023 10:39:41 +0000 Received: by outflank-mailman (input) for mailman id 641885; Mon, 27 Nov 2023 10:39:39 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yqh-0000Co-34 for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:28:19 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id ad8b86c7-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:28:17 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [10.150.64.98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id D71B321A5E; Mon, 27 Nov 2023 10:28:16 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id AE454132A6; Mon, 27 Nov 2023 10:28:16 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id PWFQKUBvZGVRfwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:28:16 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: ad8b86c7-8d0f-11ee-98e2-6d05b1d4d9a1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1701080896; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=g73YDIOfg+fr6DHKGm3oVeWr7gfJUQ0OIPzwFoMgOy0=; b=Idyyl2HRFHkHp4suzKoMv9lJBrLRoW23tRNrqihml85WGwhHTe9CvZhWKtkCN0MVe9ClQk XzfJbcpKHtuBA1UEsjIOnLLRHuRvcGupPRhOiZode3VvP7+Wb9646ItqQgt+C8aoRSDnYp dz8VnO5G7Sarjd/OuOXGKhZHb9+eQXE= From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 31/32] Mini-OS: add EXPORT_SYMBOL() instances to xenbus.c Date: Mon, 27 Nov 2023 11:25:22 +0100 Message-Id: <20231127102523.28003-32-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 Authentication-Results: smtp-out1.suse.de; none X-Spamd-Result: default: False [16.50 / 50.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(5.10)[99.99%]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; R_MISSING_CHARSET(2.50)[]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_SHORT(3.00)[1.000]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; DKIM_SIGNED(0.00)[suse.com:s=susede1]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; FUZZY_BLOCKED(0.00)[rspamd.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; RCVD_TLS_ALL(0.00)[] Add the needed instances of EXPORT_SYMBOL() to xenbus.c. Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- xenbus.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/xenbus.c b/xenbus.c index 8bfd5bd4..eb9af055 100644 --- a/xenbus.c +++ b/xenbus.c @@ -123,6 +123,7 @@ char **xenbus_wait_for_watch_return(xenbus_event_queue *queue) return &event->path; } +EXPORT_SYMBOL(xenbus_wait_for_watch_return); void xenbus_wait_for_watch(xenbus_event_queue *queue) { @@ -136,6 +137,7 @@ void xenbus_wait_for_watch(xenbus_event_queue *queue) else printk("unexpected path returned by watch\n"); } +EXPORT_SYMBOL(xenbus_wait_for_watch); void xenbus_release_wait_for_watch(xenbus_event_queue *queue) { @@ -145,6 +147,7 @@ void xenbus_release_wait_for_watch(xenbus_event_queue *queue) *queue = event; wake_up(&xenbus_watch_queue); } +EXPORT_SYMBOL(xenbus_release_wait_for_watch); char *xenbus_wait_for_value(const char *path, const char *value, xenbus_event_queue *queue) @@ -170,6 +173,7 @@ char *xenbus_wait_for_value(const char *path, const char *value, xenbus_wait_for_watch(queue); } } +EXPORT_SYMBOL(xenbus_wait_for_value); char *xenbus_switch_state(xenbus_transaction_t xbt, const char *path, XenbusState state) @@ -220,6 +224,7 @@ exit: return msg; } +EXPORT_SYMBOL(xenbus_switch_state); char *xenbus_wait_for_state_change(const char *path, XenbusState *state, xenbus_event_queue *queue) @@ -249,6 +254,7 @@ char *xenbus_wait_for_state_change(const char *path, XenbusState *state, } return NULL; } +EXPORT_SYMBOL(xenbus_wait_for_state_change); static void xenbus_read_data(char *buf, unsigned int len) { @@ -602,6 +608,7 @@ struct xsd_sockmsg *xenbus_msg_reply(int type, xenbus_transaction_t trans, return rep; } +EXPORT_SYMBOL(xenbus_msg_reply); static char *errmsg(struct xsd_sockmsg *rep) { @@ -664,6 +671,7 @@ char *xenbus_ls(xenbus_transaction_t xbt, const char *pre, char ***contents) return NULL; } +EXPORT_SYMBOL(xenbus_ls); char *xenbus_read(xenbus_transaction_t xbt, const char *path, char **value) { @@ -687,6 +695,7 @@ char *xenbus_read(xenbus_transaction_t xbt, const char *path, char **value) return NULL; } +EXPORT_SYMBOL(xenbus_read); char *xenbus_write(xenbus_transaction_t xbt, const char *path, const char *value) @@ -707,6 +716,7 @@ char *xenbus_write(xenbus_transaction_t xbt, const char *path, return NULL; } +EXPORT_SYMBOL(xenbus_write); char* xenbus_watch_path_token(xenbus_transaction_t xbt, const char *path, const char *token, xenbus_event_queue *events) @@ -738,6 +748,7 @@ char* xenbus_watch_path_token(xenbus_transaction_t xbt, const char *path, return NULL; } +EXPORT_SYMBOL(xenbus_watch_path_token); char* xenbus_unwatch_path_token(xenbus_transaction_t xbt, const char *path, const char *token) @@ -771,6 +782,7 @@ char* xenbus_unwatch_path_token(xenbus_transaction_t xbt, const char *path, return NULL; } +EXPORT_SYMBOL(xenbus_unwatch_path_token); char *xenbus_rm(xenbus_transaction_t xbt, const char *path) { @@ -787,6 +799,7 @@ char *xenbus_rm(xenbus_transaction_t xbt, const char *path) return NULL; } +EXPORT_SYMBOL(xenbus_rm); char *xenbus_get_perms(xenbus_transaction_t xbt, const char *path, char **value) { @@ -810,6 +823,7 @@ char *xenbus_get_perms(xenbus_transaction_t xbt, const char *path, char **value) return NULL; } +EXPORT_SYMBOL(xenbus_get_perms); #define PERM_MAX_SIZE 32 char *xenbus_set_perms(xenbus_transaction_t xbt, const char *path, domid_t dom, @@ -834,6 +848,7 @@ char *xenbus_set_perms(xenbus_transaction_t xbt, const char *path, domid_t dom, return NULL; } +EXPORT_SYMBOL(xenbus_set_perms); char *xenbus_transaction_start(xenbus_transaction_t *xbt) { @@ -855,6 +870,7 @@ char *xenbus_transaction_start(xenbus_transaction_t *xbt) return NULL; } +EXPORT_SYMBOL(xenbus_transaction_start); char *xenbus_transaction_end(xenbus_transaction_t t, int abort, int *retry) { @@ -883,6 +899,7 @@ char *xenbus_transaction_end(xenbus_transaction_t t, int abort, int *retry) return NULL; } +EXPORT_SYMBOL(xenbus_transaction_end); int xenbus_read_integer(const char *path) { @@ -902,6 +919,7 @@ int xenbus_read_integer(const char *path) return t; } +EXPORT_SYMBOL(xenbus_read_integer); int xenbus_read_uuid(const char *path, unsigned char uuid[16]) { @@ -935,6 +953,7 @@ int xenbus_read_uuid(const char *path, unsigned char uuid[16]) return 1; } +EXPORT_SYMBOL(xenbus_read_uuid); #define BUFFER_SIZE 256 static void xenbus_build_path(const char *dir, const char *node, char *res) @@ -957,6 +976,7 @@ char *xenbus_printf(xenbus_transaction_t xbt, const char* node, return xenbus_write(xbt,fullpath,val); } +EXPORT_SYMBOL(xenbus_printf); domid_t xenbus_get_self_id(void) { @@ -968,6 +988,7 @@ domid_t xenbus_get_self_id(void) return ret; } +EXPORT_SYMBOL(xenbus_get_self_id); char *xenbus_read_string(xenbus_transaction_t xbt, const char *dir, const char *node, char **value) @@ -978,6 +999,7 @@ char *xenbus_read_string(xenbus_transaction_t xbt, const char *dir, return xenbus_read(xbt, path, value); } +EXPORT_SYMBOL(xenbus_read_string); char *xenbus_read_unsigned(xenbus_transaction_t xbt, const char *dir, const char *node, unsigned int *value) @@ -997,6 +1019,7 @@ char *xenbus_read_unsigned(xenbus_transaction_t xbt, const char *dir, return msg; } +EXPORT_SYMBOL(xenbus_read_unsigned); /* * Local variables: From patchwork Mon Nov 27 10:25:23 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 13469345 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 5BD43C4167B for ; Mon, 27 Nov 2023 10:39:48 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.641883.1000860 (Exim 4.92) (envelope-from ) id 1r7Z1h-0001qY-7M; Mon, 27 Nov 2023 10:39:41 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 641883.1000860; Mon, 27 Nov 2023 10:39:41 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Z1h-0001pz-46; Mon, 27 Nov 2023 10:39:41 +0000 Received: by outflank-mailman (input) for mailman id 641883; Mon, 27 Nov 2023 10:39:39 +0000 Received: from se1-gles-sth1-in.inumbo.com ([159.253.27.254] helo=se1-gles-sth1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1r7Yqm-0000Co-D0 for xen-devel@lists.xenproject.org; Mon, 27 Nov 2023 10:28:24 +0000 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130]) by se1-gles-sth1.inumbo.com (Halon) with ESMTPS id b0d1e573-8d0f-11ee-98e2-6d05b1d4d9a1; Mon, 27 Nov 2023 11:28:22 +0100 (CET) Received: from imap2.dmz-prg2.suse.org (imap2.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:98]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 6289D21A5E; Mon, 27 Nov 2023 10:28:22 +0000 (UTC) Received: from imap2.dmz-prg2.suse.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by imap2.dmz-prg2.suse.org (Postfix) with ESMTPS id 38A33132A6; Mon, 27 Nov 2023 10:28:22 +0000 (UTC) Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167]) by imap2.dmz-prg2.suse.org with ESMTPSA id PgOiDEZvZGVafwAAn2gu4w (envelope-from ); Mon, 27 Nov 2023 10:28:22 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: b0d1e573-8d0f-11ee-98e2-6d05b1d4d9a1 From: Juergen Gross To: minios-devel@lists.xenproject.org, xen-devel@lists.xenproject.org Cc: samuel.thibault@ens-lyon.org, wl@xen.org, Juergen Gross Subject: [PATCH v3 32/32] Mini-OS: hide all symbols not exported via EXPORT_SYMBOLS() Date: Mon, 27 Nov 2023 11:25:23 +0100 Message-Id: <20231127102523.28003-33-jgross@suse.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20231127102523.28003-1-jgross@suse.com> References: <20231127102523.28003-1-jgross@suse.com> MIME-Version: 1.0 X-Spamd-Bar: ++++++++++++++++++++++++++ Authentication-Results: smtp-out1.suse.de; dkim=none; dmarc=fail reason="No valid SPF, No valid DKIM" header.from=suse.com (policy=quarantine); spf=fail (smtp-out1.suse.de: domain of jgross@suse.com does not designate 2a07:de40:b281:104:10:150:64:98 as permitted sender) smtp.mailfrom=jgross@suse.com X-Rspamd-Server: rspamd2 X-Spamd-Result: default: False [26.60 / 50.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; BAYES_SPAM(5.10)[100.00%]; SPAMHAUS_XBL(0.00)[2a07:de40:b281:104:10:150:64:98:from]; TO_DN_SOME(0.00)[]; R_MISSING_CHARSET(2.50)[]; BROKEN_CONTENT_TYPE(1.50)[]; RCPT_COUNT_FIVE(0.00)[5]; RCVD_COUNT_THREE(0.00)[3]; MX_GOOD(-0.01)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(2.20)[]; MIME_TRACE(0.00)[0:+]; ARC_NA(0.00)[]; R_SPF_FAIL(1.00)[-all]; FROM_HAS_DN(0.00)[]; DMARC_POLICY_QUARANTINE(1.50)[suse.com : No valid SPF, No valid DKIM,quarantine]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_SPAM_SHORT(3.00)[1.000]; MIME_GOOD(-0.10)[text/plain]; NEURAL_SPAM_LONG(3.50)[1.000]; MID_CONTAINS_FROM(1.00)[]; FUZZY_BLOCKED(0.00)[rspamd.com]; RCVD_TLS_ALL(0.00)[] X-Rspamd-Queue-Id: 6289D21A5E When doing the final linking of the Mini-OS kernel only keep the symbols visible which have been marked via EXPORT_SYMBOL(). Signed-off-by: Juergen Gross Reviewed-by: Samuel Thibault --- V3: - new patch --- Makefile | 1 + 1 file changed, 1 insertion(+) diff --git a/Makefile b/Makefile index 588496cb..456aed0b 100644 --- a/Makefile +++ b/Makefile @@ -167,6 +167,7 @@ $(OBJ_DIR)/arch/x86/minios-x86%.lds: arch/x86/minios-x86.lds.S $(OBJ_DIR)/$(TARGET)-kern.o: $(OBJS) arch_lib $(OBJ_DIR)/$(TARGET_ARCH_DIR)/minios-$(MINIOS_TARGET_ARCH).lds $(LD) -r $(LDFLAGS) $(HEAD_OBJ) $(OBJS) $(LDARCHLIB) -o $@ $(OBJCOPY) --dump-section .export_symbol=$(OBJ_DIR)/syms $@ + $(OBJCOPY) -w -G $(GLOBAL_PREFIX)* --keep-global-symbols=$(OBJ_DIR)/syms --remove-section=.export_symbol $@ $@ $(OBJ_DIR)/$(TARGET): $(OBJ_DIR)/$(TARGET)-kern.o $(APP_O) $(LD) -r $(LDFLAGS) $(OBJ_DIR)/$(TARGET)-kern.o $(APP_O) $(LDLIBS) -o $@.o