From patchwork Tue Feb 11 11:06:48 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Florian Weimer X-Patchwork-Id: 1236248 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=sourceware.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=libc-alpha-return-109449-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.a=rsa-sha1 header.s=default header.b=dzq54lZC; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=alIgkwSF; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 48H0PJ4CkQz9s29 for ; Tue, 11 Feb 2020 22:08:04 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:in-reply-to:references :message-id:date:mime-version:content-type :content-transfer-encoding; q=dns; s=default; b=biKqsFb5NvyZxMHr HAuwZ2v2QfV6ZJzyn0f17G1VcC0Cc5ckzcXToBrn5uygOtDtbdOuyr7nlkRPGUvY J9aH/rctZHa2Va754dwxbRIYC0rvGt06pV5mFaVZ+unMpCGR4635BuyXqV9r7tqh /pAzUJ26PYgJ3dF/oGYYovcBJSU= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:in-reply-to:references :message-id:date:mime-version:content-type :content-transfer-encoding; s=default; bh=52MZ9SAKN/RcWu6L4SVmVN rPhQk=; b=dzq54lZCjIC4Jd46lJPjR5h0lTWUj3On1cJA54Hzh5cJRXkTeNeA+D 4JDAQUBoYyIZWo2vX1jSM0OdbjmB1TYwoBTfppcCFSy0L4AK9TbS5+2M8SKc98T8 K+nKcrDYA9hOTxgQQBkU+Z2DgpEoH++5IcifShoBfPc9t9H3BXfzg= Received: (qmail 11840 invoked by alias); 11 Feb 2020 11:06:58 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 11770 invoked by uid 89); 11 Feb 2020 11:06:57 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-18.9 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 spammy= X-HELO: us-smtp-delivery-1.mimecast.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581419215; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=fXqteEOvLYtt2xmPZiBAgHqhux0DXKyCkBsB9ZQtW/o=; b=alIgkwSF7thuRjN4XJexta9LxrDI+pjnBIEDNyUo/eY1dTENw28RuC89c1dZBHn8I5QML4 qp0e+ZXLMEIko87770WK7OSVZkKUWsZ5V0yHUAqzQ+j5K1kaxIIGv05rgEiM1HVom/gSvT RkJ/IWnYRF58sjpqKM1tIB/OYVI61EM= From: Florian Weimer To: libc-alpha@sourceware.org Subject: [PATCH 11/13] Add hidden prototypes for __sched_getparam, __sched_getscheduler In-Reply-To: References: X-From-Line: 296f37bf50e98512ee7783ca85f8610da96cbd25 Mon Sep 17 00:00:00 2001 Message-Id: <296f37bf50e98512ee7783ca85f8610da96cbd25.1581418947.git.fweimer@redhat.com> Date: Tue, 11 Feb 2020 12:06:48 +0100 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com This will enable them to be used in libc.so without PLTs. Reviewed-by: Adhemerval Zanella --- include/sched.h | 2 ++ posix/sched_getp.c | 1 + posix/sched_gets.c | 1 + 3 files changed, 4 insertions(+) diff --git a/include/sched.h b/include/sched.h index 4abc440176..b0bf971c93 100644 --- a/include/sched.h +++ b/include/sched.h @@ -7,10 +7,12 @@ extern int __sched_setparam (__pid_t __pid, const struct sched_param *__param); libc_hidden_proto (__sched_setparam) extern int __sched_getparam (__pid_t __pid, struct sched_param *__param); +libc_hidden_proto (__sched_getparam) extern int __sched_setscheduler (__pid_t __pid, int __policy, const struct sched_param *__param); libc_hidden_proto (__sched_setscheduler) extern int __sched_getscheduler (__pid_t __pid); +libc_hidden_proto (__sched_getscheduler) extern int __sched_yield (void); libc_hidden_proto (__sched_yield) extern int __sched_get_priority_max (int __algorithm); diff --git a/posix/sched_getp.c b/posix/sched_getp.c index 32a5087850..014ea0f7ce 100644 --- a/posix/sched_getp.c +++ b/posix/sched_getp.c @@ -27,6 +27,7 @@ __sched_getparam (pid_t pid, struct sched_param *param) __set_errno (ENOSYS); return -1; } +libc_hidden_def (__sched_getparam) stub_warning (sched_getparam) weak_alias (__sched_getparam, sched_getparam) diff --git a/posix/sched_gets.c b/posix/sched_gets.c index 356e2f22fe..07dd67054f 100644 --- a/posix/sched_gets.c +++ b/posix/sched_gets.c @@ -27,6 +27,7 @@ __sched_getscheduler (pid_t pid) __set_errno (ENOSYS); return -1; } +libc_hidden_def (__sched_getscheduler) stub_warning (sched_getscheduler) weak_alias (__sched_getscheduler, sched_getscheduler)