Received: by 10.223.185.116 with SMTP id b49csp1122277wrg; Fri, 23 Feb 2018 12:18:50 -0800 (PST) X-Google-Smtp-Source: AH8x227u10cXXik0OdcVMwp2+BWmLKAqMoQGnw4WCH2NUufiuk+XVzDD6zZrivAdGUGVSgmKktRW X-Received: by 10.99.186.22 with SMTP id k22mr2251569pgf.7.1519417129959; Fri, 23 Feb 2018 12:18:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519417129; cv=none; d=google.com; s=arc-20160816; b=jXjE8fnpmrA/As5+DomDNQQgDpCrJKLP9+UQJ5eIZujS/IMFIxQIodeIdR9+U4svyh 0I+Cs4FXc84b2BCyZPY28kCrTT7AGSA2zNsxRJMKDHL2MGjrFruUUHz9nz90AbZmDVW5 nFyH85HH/ARZuy7e7SsE9OWQlWwI5aM+WR7SF1d3PY6NuKbFrzothc8OvfOKX61wFXSY W6uMg///yYPV0laj77ypa1d1AFqk2UK498sZIFuDXhtUVC8gFaswAkD8QVz+NoQhizHn 6hZB772wQr1MQu0HH3HxWi0dPY1UUBH1Q476Opn1TMGPRrPE9SB7+IPuh2piHO2aMv4A xFZw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=iBKXR6AeJ0Oob0bJy1+DhT5rGFa+a7dcRDucSotqlIw=; b=KftyhPi0BzMejWU5fLeEHy+rPC3+VgRrkpaBymlpht5s80lL3c/nKRtJCxvPmJzM9T kKyiZ+kxaaexNwJU6XlmcPVqe1Ah5uvusV+4evmSnWP9/J188O8NzjY6q+RaIs3bnAWF C0MPb7hSWyykxHVnaNyGpLjBVfEhWKbiRQhuxgFpXVhKi6vVCVXMLQPTc/vIfg9rfld9 VmFkGgq5qqyqN3eh7bUoxD2Gq7V+LKqu7LnT+UQ6OUs87GzPL97Pss0Cjfc8JupGooJy V0k5jGLr3nqgtjiU5aviTEI6bBN5tquFb4uC+1xK3iLrsRKh75uCt44SLYMEygcMKMOe gALg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l62si2324260pfl.160.2018.02.23.12.18.35; Fri, 23 Feb 2018 12:18:49 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932535AbeBWSj5 (ORCPT + 99 others); Fri, 23 Feb 2018 13:39:57 -0500 Received: from mail.linuxfoundation.org ([140.211.169.12]:39840 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754407AbeBWSjx (ORCPT ); Fri, 23 Feb 2018 13:39:53 -0500 Received: from localhost (LFbn-1-12258-90.w90-92.abo.wanadoo.fr [90.92.71.90]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 555451182; Fri, 23 Feb 2018 18:39:52 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Greg Kroah-Hartman , Arnd Bergmann Subject: [PATCH 4.4 152/193] binfmt_elf: compat: avoid unused function warning Date: Fri, 23 Feb 2018 19:26:25 +0100 Message-Id: <20180223170349.766396281@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180223170325.997716448@linuxfoundation.org> References: <20180223170325.997716448@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.4-stable review patch. If anyone has any objections, please let me know. ------------------ From: Arnd Bergmann When CONFIG_ELF_CORE is disabled, we get a harmless warning in the compat version of binfmt_elf: fs/compat_binfmt_elf.c:58:13: error: 'cputime_to_compat_timeval' defined but not used [-Werror=unused-function] This was addressed in mainline Linux as part of a larger rework with commit cd19c364b313 ("fs/binfmt: Convert obsolete cputime type to nsecs"). For 4.9 and earlier, this just shuts up the warning by adding an #ifdef around the function definition. Signed-off-by: Arnd Bergmann Signed-off-by: Greg Kroah-Hartman --- fs/compat_binfmt_elf.c | 2 ++ 1 file changed, 2 insertions(+) --- a/fs/compat_binfmt_elf.c +++ b/fs/compat_binfmt_elf.c @@ -51,6 +51,7 @@ #define elf_prstatus compat_elf_prstatus #define elf_prpsinfo compat_elf_prpsinfo +#ifdef CONFIG_ELF_CORE /* * Compat version of cputime_to_compat_timeval, perhaps this * should be an inline in . @@ -63,6 +64,7 @@ static void cputime_to_compat_timeval(co value->tv_sec = tv.tv_sec; value->tv_usec = tv.tv_usec; } +#endif #undef cputime_to_timeval #define cputime_to_timeval cputime_to_compat_timeval