From patchwork Thu Dec 14 06:29:06 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stafford Horne X-Patchwork-Id: 848380 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=uclibc-ng.org (client-ip=89.238.66.15; helo=helium.openadk.org; envelope-from=devel-bounces@uclibc-ng.org; receiver=) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="UISiR4Uj"; dkim-atps=neutral Received: from helium.openadk.org (helium.openadk.org [89.238.66.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3yy3Yv5jG7z9s83 for ; Thu, 14 Dec 2017 17:29:23 +1100 (AEDT) Received: from helium.openadk.org (localhost [IPv6:::1]) by helium.openadk.org (Postfix) with ESMTP id B80F810746; Thu, 14 Dec 2017 07:29:20 +0100 (CET) X-Original-To: devel@uclibc-ng.org Delivered-To: devel@helium.openadk.org Received: from mail-pf0-f195.google.com (mail-pf0-f195.google.com [209.85.192.195]) by helium.openadk.org (Postfix) with ESMTPS id 00A08106F9 for ; Thu, 14 Dec 2017 07:29:18 +0100 (CET) Received: by mail-pf0-f195.google.com with SMTP id j28so2972941pfk.8 for ; Wed, 13 Dec 2017 22:29:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=v/3OiQl0tdMLdQTdyajcgJcCsVLazK4ygJg7guHdiQY=; b=UISiR4UjXoglz1AMHu9rLAHYU7oX6fIldkCHAwHxnY2GLKF/VE7DTrPm1WXeeXu7/v TexEv4ZFn4nr3S/eNX1VVn5lT4s7yCWJV78IZZ30bxzHTbrlHyXJxgvHaozg3g58MACo yBD6k4IQ6WsgPbTdByK8D61DV0gaaPvKnSajUbklMkMAo/sY8CZp5hsqGSrzfDi0A5io H8zQ7XwXtcWAgMMJDGAMwVsHeVbEUbDoBu27fmiTYypmuz4SXt3mcqDo8Q2V83Lv0VcU jhc5zN1cUJdO44PwGOJURSomQzTkV4ie/ytkWPMTQve+yYJ7Jzj+bhGzsRR7etBvWi0G +bAg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=v/3OiQl0tdMLdQTdyajcgJcCsVLazK4ygJg7guHdiQY=; b=BcCfY06mQ5DSpLJ+iNyQ3Kz1pMQbHAGyiLxnpRlayEBEBcK1iYGQfWok2fOMaXssIX mRS6c6S5QzP69i6wSHBOLXLzS4A1dT50mvQsv5AYo65HYtaPQrPn3PZZONAxHYroku9D JTgBMiXfIQ4qcVUAFZfATc2XUOZzbmDiHlj5Mf4yrdskfSuCla7z8LJQ1p3bFOmXeOpK aBtt4KrM3q3YAKN/kmzVMY1Z/5bXmq/ni7SnJX1yavKrSPatMK02aGJ3t6MkK37NmAn1 Rn+laEOzAncoPZ6+GxgOCc3Uspf9yzGlEC08HEVURf5gNUfUwTgJMD7ELltzrmpxUJUt vB2g== X-Gm-Message-State: AKGB3mLEr7D9Wzm7nQmSzyMjh58JqgIeYFxs7Uw9hsmVp8y7zt1jmOb4 d5D4RiTFPpM2PeI5DtaHEW9HyN8v X-Google-Smtp-Source: ACJfBougF5tOS/HZVjJPTig7rZDTOUWhkI84D564joQFAkV6h07sWON/XH+0lQYFiaWvcqBqGlcsAg== X-Received: by 10.84.169.36 with SMTP id g33mr8261830plb.83.1513232956305; Wed, 13 Dec 2017 22:29:16 -0800 (PST) Received: from localhost (g41.219-103-184.ppp.wakwak.ne.jp. [219.103.184.41]) by smtp.gmail.com with ESMTPSA id b10sm6103535pfj.20.2017.12.13.22.29.15 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 13 Dec 2017 22:29:15 -0800 (PST) From: Stafford Horne To: uclibc-ng Devel Date: Thu, 14 Dec 2017 15:29:06 +0900 Message-Id: <20171214062909.8602-2-shorne@gmail.com> X-Mailer: git-send-email 2.13.6 In-Reply-To: <20171214062909.8602-1-shorne@gmail.com> References: <20171214062909.8602-1-shorne@gmail.com> Subject: [uclibc-ng-devel] [PATCH 1/4] syscall: Make common implementation match unistd.h X-BeenThere: devel@uclibc-ng.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: uClibc-ng Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: devel-bounces@uclibc-ng.org Sender: "devel" The definition of syscall() in unistd.h is with varargs. Traditionally the common implementation in uclibc has been with regular arguments. This patch updates that by using varargs. This has caused issues on architectures like or1k which have different calling conventions for varargs and regular arg parameters. The implementation here is based on an implementation from Joel Stanley . There is a difference that I do not initialize the stack args with 0 as they are immediately overwritten by va_args. Signed-off-by: Stafford Horne --- libc/sysdeps/linux/common/syscall.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/libc/sysdeps/linux/common/syscall.c b/libc/sysdeps/linux/common/syscall.c index 61f798e2c..d173d2c54 100644 --- a/libc/sysdeps/linux/common/syscall.c +++ b/libc/sysdeps/linux/common/syscall.c @@ -4,9 +4,25 @@ * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. */ +#include #include +#include -long syscall(long sysnum, long arg1, long arg2, long arg3, long arg4, long arg5, long arg6) +long syscall(long sysnum, ...) { + + unsigned long arg1, arg2, arg3, arg4, arg5, arg6; + va_list arg; + + va_start (arg, sysnum); + arg1 = va_arg (arg, unsigned long); + arg2 = va_arg (arg, unsigned long); + arg3 = va_arg (arg, unsigned long); + arg4 = va_arg (arg, unsigned long); + arg5 = va_arg (arg, unsigned long); + arg6 = va_arg (arg, unsigned long); + va_end (arg); + + __asm__ volatile ( "" ::: "memory" ); return INLINE_SYSCALL_NCS(sysnum, 6, arg1, arg2, arg3, arg4, arg5, arg6); } From patchwork Thu Dec 14 06:29:07 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stafford Horne X-Patchwork-Id: 848381 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=uclibc-ng.org (client-ip=89.238.66.15; helo=helium.openadk.org; envelope-from=devel-bounces@uclibc-ng.org; receiver=) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="K/ViV8FU"; dkim-atps=neutral Received: from helium.openadk.org (helium.openadk.org [89.238.66.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3yy3Yy5fPBz9s83 for ; Thu, 14 Dec 2017 17:29:26 +1100 (AEDT) Received: from helium.openadk.org (localhost [IPv6:::1]) by helium.openadk.org (Postfix) with ESMTP id 443E6106F9; Thu, 14 Dec 2017 07:29:23 +0100 (CET) X-Original-To: devel@uclibc-ng.org Delivered-To: devel@helium.openadk.org Received: from mail-pg0-f65.google.com (mail-pg0-f65.google.com [74.125.83.65]) by helium.openadk.org (Postfix) with ESMTPS id B294A106F9 for ; Thu, 14 Dec 2017 07:29:20 +0100 (CET) Received: by mail-pg0-f65.google.com with SMTP id j9so2810493pgc.11 for ; Wed, 13 Dec 2017 22:29:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=TBu83esbx2ptUldqm08OzR/A3i7rQGFEsxcSrwZUeHA=; b=K/ViV8FUQ6WMMeu1jDLYLeiFX3kSt9feHuCeU3Y0mNWZPaDdwZlpqVGALHJVoJFefo IdJ4biX0GSGNjd8Q+r4V9ZcJV+ue7YwSjFMa8WsuI2sFTbgprwu2uXUxtPeZIcn2P412 1jFfTU3WTgpaDhzkUfvy0ho46hrEp14pEb7Nh4zopNm85H0jPWteZ539bQMolqCCjcTW mr0ojUd49JkmYyUf1zmL45rBavdcgF2FXy82tP5NbqeuWyEJrDnkbEP/ufw1eIXEY96+ yiQ5NxoVz5y9ptYfl1O77Oo1g8i5JfZE6jX9+m8/qD0nLSbyDtA4nWWJOvR4EZ3/baxw lxfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=TBu83esbx2ptUldqm08OzR/A3i7rQGFEsxcSrwZUeHA=; b=CPJKpKAUNsG+n69mQvMGELdmCLbzuCzNTUbuEjo0HeUB2d3PhLQ0ZnO/yB0jwr3O7a fMWP94mOBwlUYHPBKJAOIvnsUETqKf4pak1s22NdBLH8ZNEMwd3wFdjIOLur+ZHZxKgs LMvinQDj0TgYMO638wmTXQklzzcYb6fh3oL66BdUmoR28Xx1wYXpBgjUHN+vmy+y3UUZ 6P/xCv2C4vqqp0R1Cm5UsJMoRNul+Am0HWNvDheLNCQPa0hYs4NSTZxSzl71NlAUGmKB ASQvnI4LB4LST+gmXWI8i0ciuo0fQxd2TEMspHHu33Zy3ffstrzDcfZcy45BLW3UXIto mVkQ== X-Gm-Message-State: AKGB3mKMweSDLfwW0ejgoXFLXegGN+nug382qe38RkI7RdrumgXJyjwv jgfWe74Ii7YvFm6NSG/lfKUjN1u0 X-Google-Smtp-Source: ACJfBotXK6N6Ju86B/ZGF5z6WJRyA9ahUWmMagA6ow/A5nnUl/59pd0RKoCwo+AI/t68SM4daeUoNg== X-Received: by 10.99.125.23 with SMTP id y23mr7683993pgc.345.1513232959145; Wed, 13 Dec 2017 22:29:19 -0800 (PST) Received: from localhost (g41.219-103-184.ppp.wakwak.ne.jp. [219.103.184.41]) by smtp.gmail.com with ESMTPSA id 65sm1130386pgj.55.2017.12.13.22.29.18 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 13 Dec 2017 22:29:18 -0800 (PST) From: Stafford Horne To: uclibc-ng Devel Date: Thu, 14 Dec 2017 15:29:07 +0900 Message-Id: <20171214062909.8602-3-shorne@gmail.com> X-Mailer: git-send-email 2.13.6 In-Reply-To: <20171214062909.8602-1-shorne@gmail.com> References: <20171214062909.8602-1-shorne@gmail.com> Subject: [uclibc-ng-devel] [PATCH 2/4] or1k: Use new common syscall() implementation X-BeenThere: devel@uclibc-ng.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: uClibc-ng Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: devel-bounces@uclibc-ng.org Sender: "devel" Now that the common syscall implementation supports vararg calling conventions we can safely use it on OpenRISC. This saves a bit of code in the openrisc implementation. Signed-off-by: Stafford Horne --- libc/sysdeps/linux/or1k/Makefile.arch | 2 +- libc/sysdeps/linux/or1k/syscall.c | 32 -------------------------------- 2 files changed, 1 insertion(+), 33 deletions(-) delete mode 100644 libc/sysdeps/linux/or1k/syscall.c diff --git a/libc/sysdeps/linux/or1k/Makefile.arch b/libc/sysdeps/linux/or1k/Makefile.arch index 191eebafd..f6758fa63 100644 --- a/libc/sysdeps/linux/or1k/Makefile.arch +++ b/libc/sysdeps/linux/or1k/Makefile.arch @@ -5,5 +5,5 @@ # Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. # -CSRC-y := __syscall_error.c __init_brk.c brk.c sbrk.c clone.c syscall.c +CSRC-y := __syscall_error.c __init_brk.c brk.c sbrk.c clone.c SSRC-y := __longjmp.S setjmp.S or1k_clone.S diff --git a/libc/sysdeps/linux/or1k/syscall.c b/libc/sysdeps/linux/or1k/syscall.c deleted file mode 100644 index 2f4356737..000000000 --- a/libc/sysdeps/linux/or1k/syscall.c +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright (C) 2017 Joel Stanley - * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. - */ - -#include -#include -#include - -long int syscall (long num, ...) -{ - unsigned long arg1 = 0; - unsigned long arg2 = 0; - unsigned long arg3 = 0; - unsigned long arg4 = 0; - unsigned long arg5 = 0; - unsigned long arg6 = 0; - va_list arg; - - va_start (arg, num); - arg1 = va_arg (arg, unsigned long); - arg2 = va_arg (arg, unsigned long); - arg3 = va_arg (arg, unsigned long); - arg4 = va_arg (arg, unsigned long); - arg5 = va_arg (arg, unsigned long); - arg6 = va_arg (arg, unsigned long); - va_end (arg); - - __asm__ volatile ( "" ::: "memory" ); - - return INLINE_SYSCALL_NCS(num, 6, arg1, arg2, arg3, arg4, arg5, arg6); -} From patchwork Thu Dec 14 06:29:08 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stafford Horne X-Patchwork-Id: 848383 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=uclibc-ng.org (client-ip=89.238.66.15; helo=helium.openadk.org; envelope-from=devel-bounces@uclibc-ng.org; receiver=) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="mOIfsPBS"; dkim-atps=neutral Received: from helium.openadk.org (helium.openadk.org [89.238.66.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3yy3Z26Tqqz9s83 for ; Thu, 14 Dec 2017 17:29:30 +1100 (AEDT) Received: from helium.openadk.org (localhost [IPv6:::1]) by helium.openadk.org (Postfix) with ESMTP id A89A6106FD; Thu, 14 Dec 2017 07:29:27 +0100 (CET) X-Original-To: devel@uclibc-ng.org Delivered-To: devel@helium.openadk.org Received: from mail-pf0-f193.google.com (mail-pf0-f193.google.com [209.85.192.193]) by helium.openadk.org (Postfix) with ESMTPS id 5A3E6106FD for ; Thu, 14 Dec 2017 07:29:23 +0100 (CET) Received: by mail-pf0-f193.google.com with SMTP id d23so2970613pfe.9 for ; Wed, 13 Dec 2017 22:29:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=GPsRzCZG+/5PvELCq6jzGkxBMYSyxmiZnXdQe4xFdX4=; b=mOIfsPBS0ldOXXFSaPF2Ue2McG5A+Sx3BX0xTOO9L9wR5MK2K9QWTw+XdSGTuQWAVJ GL3FFesl0W/lrS/hcUEB57YqtsODWNZmU9NXhxSlijWix2/PkKwbrqXbtfWOQAf/3zMc O72fU2X//DP80WNzzkxBc5AR92EjXzeGlm7KWrnV1K/7OMhj1uXl059Xza/qTl8yTclq becAYjJEGX8C1e8grgzFROFqwmlCH611HhwSVWgXSKARn649wWHbHTfYcRf3si1VjXFd 50bmOxxycJw7ofM/ewC+rzQxRCWTGu84LcmFZPFu9IUG9hU527Hnf/bA49ojJmJs2/AP pMMQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=GPsRzCZG+/5PvELCq6jzGkxBMYSyxmiZnXdQe4xFdX4=; b=ZjUV+HIGWHd56UKVKjOttSDjhbXD0K7P50tPsZQaF2uoPSgaZyd4vXHMmcFqAwz/2f JbFwLjQxTLVTDcTISNBUx0qVU9l2K986UdbwIlTErmNAQXtk+RBU/dhOTCAqHTIGyw9H dDCcLGrfxltEbRNjKL9qP1MuNtnSgeJ7BlqDwaOswndltF+cZMCw7Jik7e2EeyLoY0k/ Um/rWRZWK0vi1uhI37kQW9HFTPyLlIlWEuwU2bUxw+fMlYfC/IkSZ/yy43LxDr1NnUTC 88IHbJ54xhf2FDHa/tvHxauavjJud5raPrIvK/58et2VEp+cSy3eBWs2zqwJx7LrgN1N VyVA== X-Gm-Message-State: AKGB3mKeMD6iPCHbg3gRuNkdvV25OlBh5/t3/NuiuYiAINQd/WAl83dg DP6fDeY6ehz2brn8/tmT1D3svPRI X-Google-Smtp-Source: ACJfBot2UwXCkhl52xTwepjn548e5FO5NFTXqJMcO727dqZehEe6bd5NbL9b/Brt/BGfeCa47OowVg== X-Received: by 10.159.244.131 with SMTP id y3mr8634165plr.244.1513232961478; Wed, 13 Dec 2017 22:29:21 -0800 (PST) Received: from localhost (g41.219-103-184.ppp.wakwak.ne.jp. [219.103.184.41]) by smtp.gmail.com with ESMTPSA id j6sm6190355pfg.85.2017.12.13.22.29.20 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 13 Dec 2017 22:29:21 -0800 (PST) From: Stafford Horne To: uclibc-ng Devel Date: Thu, 14 Dec 2017 15:29:08 +0900 Message-Id: <20171214062909.8602-4-shorne@gmail.com> X-Mailer: git-send-email 2.13.6 In-Reply-To: <20171214062909.8602-1-shorne@gmail.com> References: <20171214062909.8602-1-shorne@gmail.com> Subject: [uclibc-ng-devel] [PATCH 3/4] nds32: Use new common syscall() implementation X-BeenThere: devel@uclibc-ng.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: uClibc-ng Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: devel-bounces@uclibc-ng.org Sender: "devel" Traditionally nds32 has had a generic syscall implementation supporting varargs. During an audit it was found that this implementation seems to duplicate the new common implementation and is no longer needed. Signed-off-by: Stafford Horne --- libc/sysdeps/linux/nds32/Makefile.arch | 4 ++-- libc/sysdeps/linux/nds32/syscall.c | 28 ---------------------------- 2 files changed, 2 insertions(+), 30 deletions(-) delete mode 100644 libc/sysdeps/linux/nds32/syscall.c diff --git a/libc/sysdeps/linux/nds32/Makefile.arch b/libc/sysdeps/linux/nds32/Makefile.arch index d5cdddbfa..caf163844 100644 --- a/libc/sysdeps/linux/nds32/Makefile.arch +++ b/libc/sysdeps/linux/nds32/Makefile.arch @@ -1,7 +1,7 @@ # Copyright (C) 2016 Andes Technology, Inc. # Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. -CSRC-y := brk.c prctl.c mremap.c syscall.c -SSRC-y := setjmp.S __longjmp.S bsd-setjmp.S bsd-_setjmp.S clone.S vfork.S sysdep.S syscall.S +CSRC-y := brk.c prctl.c mremap.c +SSRC-y := setjmp.S __longjmp.S bsd-setjmp.S bsd-_setjmp.S clone.S vfork.S sysdep.S CSRC-$(UCLIBC_HAS_CONTEXT_FUNCS) += makecontext.c swapcontext.c SSRC-$(UCLIBC_HAS_CONTEXT_FUNCS) += getcontext.S setcontext.S diff --git a/libc/sysdeps/linux/nds32/syscall.c b/libc/sysdeps/linux/nds32/syscall.c deleted file mode 100644 index 2c949ef3a..000000000 --- a/libc/sysdeps/linux/nds32/syscall.c +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Copyright (C) 2017 Andes Technology, Inc. - * Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball. - */ - -#include -#include -#include -#include -#include -long int syscall (long int __sysno, ...) -{ - - int result; - unsigned long arg1,arg2,arg3,arg4,arg5,arg6; - va_list arg; - va_start (arg, __sysno); - arg1 = va_arg (arg, unsigned long); - arg2 = va_arg (arg, unsigned long); - arg3 = va_arg (arg, unsigned long); - arg4 = va_arg (arg, unsigned long); - arg5 = va_arg (arg, unsigned long); - arg6 = va_arg (arg, unsigned long); - va_end (arg); - __asm__ volatile ( "" ::: "memory" ); - result = INLINE_SYSCALL(syscall,7,__sysno,arg1,arg2,arg3,arg4,arg5,arg6); - return result; -} From patchwork Thu Dec 14 06:29:09 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stafford Horne X-Patchwork-Id: 848382 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=uclibc-ng.org (client-ip=2a00:1828:2000:679::23; helo=helium.openadk.org; envelope-from=devel-bounces@uclibc-ng.org; receiver=) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="lITjj4ag"; dkim-atps=neutral Received: from helium.openadk.org (helium.openadk.org [IPv6:2a00:1828:2000:679::23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3yy3Z26g11z9sR8 for ; Thu, 14 Dec 2017 17:29:30 +1100 (AEDT) Received: from helium.openadk.org (localhost [IPv6:::1]) by helium.openadk.org (Postfix) with ESMTP id 35B0D10752; Thu, 14 Dec 2017 07:29:28 +0100 (CET) X-Original-To: devel@uclibc-ng.org Delivered-To: devel@helium.openadk.org Received: from mail-pf0-f194.google.com (mail-pf0-f194.google.com [209.85.192.194]) by helium.openadk.org (Postfix) with ESMTPS id E7DF7106FD for ; Thu, 14 Dec 2017 07:29:25 +0100 (CET) Received: by mail-pf0-f194.google.com with SMTP id j124so2988192pfc.2 for ; Wed, 13 Dec 2017 22:29:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=DenLwDrNVgUWBOfFkY6AhKbM3eyfs1uLQfzdh97ItZ8=; b=lITjj4agG8L+Iyqr1CvfEhpMoWjsLoCJlCUSQIvhP8hTRP2fB+YOQc9SBz/WoTeh23 Wq6AQSQodoAFbrG8k2NIp4JqSxy9sbXd4oDnp3loFKoD/YYZXVwaApgbDLRyr50q4DwF Urgx5DV8/j5ghmydVcCMH2oO8EV7aop2oeXBlgYEzgGP4kc4rRBhO1Bw1Rf4D95bP/YT mxpnMRd2kofofY7zOmiAY2agpU85CnVzzHziLDQ0tyfpqpnF3wJ+jYzo45MN2wviuG6k 8aN1q3uKMAM4p8cCkvU4za4gfrwcXw7Fz4dgY5+K4YUQYjTfxjSoWp41GxZarOQ4Cxir w28g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=DenLwDrNVgUWBOfFkY6AhKbM3eyfs1uLQfzdh97ItZ8=; b=DlXLNSFQlHfC42FAGbYu1cQWuqQe4hgQi3CmyaI9GIjsJU3njbcx5BcHVESmcu6PsI mx0i5n9+zyNusYvqerKM+y00oOK117lRw09clvSWymJ699ibAKgs/VkhjmMvizD7zf8l UVCTmmyrlNuUTbrBAeJoqLlCDLc8lOLc2xYw023kVoM/aNW/5FsSMSilLGUn16919i0f vXX0o4AmJ9RYnEmIit0yyTQnaIt4TLh83/XU8YINWET6+1Fk1PdpCreclZEOlwPHYebq WJbSdJx7Becgzs/GLMZuGfUUSvFVDcGXB5ZXOWSTIR49gwKvp4yQ9AfM69xfafxxTfvY 1hyw== X-Gm-Message-State: AKGB3mI+hqvdEibxVov7oZKoB3oGTHI/XwENRBccUBVjvpQfopTdga/f itgrf55QWd0mfPA3LC3o7gVHOGMQ X-Google-Smtp-Source: ACJfBovtRzEgYh7Vuuvk9FDT18vSza1BoxrBIhDz93FgJ0KO5Q/3xi57PX3SXbR6tWjhyTuPSUVZMg== X-Received: by 10.84.240.68 with SMTP id h4mr8435740plt.431.1513232963868; Wed, 13 Dec 2017 22:29:23 -0800 (PST) Received: from localhost (g41.219-103-184.ppp.wakwak.ne.jp. [219.103.184.41]) by smtp.gmail.com with ESMTPSA id q74sm6182147pfd.134.2017.12.13.22.29.23 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 13 Dec 2017 22:29:23 -0800 (PST) From: Stafford Horne To: uclibc-ng Devel Date: Thu, 14 Dec 2017 15:29:09 +0900 Message-Id: <20171214062909.8602-5-shorne@gmail.com> X-Mailer: git-send-email 2.13.6 In-Reply-To: <20171214062909.8602-1-shorne@gmail.com> References: <20171214062909.8602-1-shorne@gmail.com> Subject: [uclibc-ng-devel] [PATCH 4/4] arc: Use new common syscall() implementation X-BeenThere: devel@uclibc-ng.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: uClibc-ng Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: devel-bounces@uclibc-ng.org Sender: "devel" Traditionally arc has had a generic syscall implementation of syscall() matchig the common implementation. During an audit it was found that this implementation seems to duplicate common implementation and is no longer needed. Signed-off-by: Stafford Horne --- libc/sysdeps/linux/arc/Makefile.arch | 2 +- libc/sysdeps/linux/arc/syscall.c | 17 ----------------- 2 files changed, 1 insertion(+), 18 deletions(-) delete mode 100644 libc/sysdeps/linux/arc/syscall.c diff --git a/libc/sysdeps/linux/arc/Makefile.arch b/libc/sysdeps/linux/arc/Makefile.arch index a4aa72c0a..7591a9892 100644 --- a/libc/sysdeps/linux/arc/Makefile.arch +++ b/libc/sysdeps/linux/arc/Makefile.arch @@ -5,7 +5,7 @@ # Licensed under the LGPL v2.1 or later, see the file COPYING.LIB in this tarball. # -CSRC-y := syscall.c sigaction.c __syscall_error.c cacheflush.c +CSRC-y := sigaction.c __syscall_error.c cacheflush.c SSRC-y := __longjmp.S setjmp.S bsd-setjmp.S bsd-_setjmp.S vfork.S clone.S \ sigrestorer.S diff --git a/libc/sysdeps/linux/arc/syscall.c b/libc/sysdeps/linux/arc/syscall.c deleted file mode 100644 index 5648b0e1f..000000000 --- a/libc/sysdeps/linux/arc/syscall.c +++ /dev/null @@ -1,17 +0,0 @@ -/* - * Copyright (C) 2013 Synopsys, Inc. (www.synopsys.com) - * - * Licensed under the LGPL v2.1 or later, see the file COPYING.LIB in this tarball. - */ - -#include -#include -#include -#include - -extern long syscall(long int sysnum, long a, long b, long c, long d, long e, long f); - -long syscall(long int sysnum, long a, long b, long c, long d, long e, long f) -{ - return INLINE_SYSCALL_NCS(sysnum, 6, a, b, c, d, e, f); -}