From patchwork Mon Dec 11 12:50:24 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergey Senozhatsky X-Patchwork-Id: 846979 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=lists.infradead.org (client-ip=65.50.211.133; helo=bombadil.infradead.org; envelope-from=linux-snps-arc-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="ovVE42ht"; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=infradead.org header.i=@infradead.org header.b="TX1g55Eq"; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="RKFHbOhn"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3ywNY86DMJz9s4q for ; Tue, 12 Dec 2017 00:07:56 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=KQ9BLqdTTPuJVI65RaY1fQE8AF+eRN9ISJokfxA9Bc4=; b=ovVE42htS9307XN9mHeQkxUpwq QoDrAy6PdDUzs8YX0SE/0lCwvuSXtOeWyl49HtdMF2zALds4ZGgzN3Cu5tsdxy7hkSIfBt+zd9NdR I02WVdoccwGWT3myt7BGmiZz/0znsBnuf4hUTFVnJBZTSgQrfD/QXbmRfhmyaVyk3AT74pC3kvCq2 SXINLDdL91nkBdlZFP609LsnLSQD97P9nUNl118BuiEM0zMplIcd1OZJu9XjtPjNTK+OQkKPP2PTs i4+uMPfSm7WVELwCHMHGEvDIYo5cYKNuY8T70sC8IogLxBDGRptl8+3vaY8oixpUKxCGJt1sMBB03 s+GfIXNg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1eONoI-00084w-OD; Mon, 11 Dec 2017 13:07:54 +0000 Received: from casper.infradead.org ([2001:8b0:10b:1236::1]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1eONno-0007Ve-Eq; Mon, 11 Dec 2017 13:07:24 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=4gpCZ1HgjbQGL1JUxzN3eohvcZbn2hh+V3Tw9r9L/t0=; b=TX1g55EqyQqEDmfSly0LNjmpG sAnvkWj8ehXap1dr5+TsQdfM6VeE0XE76IeRi/6Yo89NK4WAe/wv/rTu0GaKw1TzzYGWjQch98M1c AH7WhfDZoW6XODQyU+7Dj0JYdHXHtgBUkBua27+uNCbB30h+ZqQbTpb9gN5oQVBY4uA4cGGr5IoEx ffkt5nZK8nslF3Cpqws88N1oVpu8G7C9v3jjsNWDDV1uHGmeWPk/j5M+xvL5YiefLvNuzlphBPoU5 v+/QK1fMEo/zEjpiVlWUsuQeQcfbG9u/JU9gaKCAbmzzgCcCGw1VQsnkYzk3N7lJpJL8bnAG6h3oj p/wX4raDQ==; Received: from mail-pf0-x244.google.com ([2607:f8b0:400e:c00::244]) by casper.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1eONaK-000196-E0; Mon, 11 Dec 2017 12:53:30 +0000 Received: by mail-pf0-x244.google.com with SMTP id p84so11474400pfd.3; Mon, 11 Dec 2017 04:53:08 -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=4gpCZ1HgjbQGL1JUxzN3eohvcZbn2hh+V3Tw9r9L/t0=; b=RKFHbOhnhewTSuijTf/z5y77qWuXPzk/4kyP+gfh6HNJ2cNwYDPq9Sxp1GPSWFTr1u qwij+71CjQQnp+SJmjYvcE2zVqPLuualB99633o101liH1hgpJacwU1a+9F6Xi77W+d5 fA2DpqSF2dnt7a4po9ShbbjJmezXrWqWBmFuCM9vo7RPl96+qp9WoHiCW2YEPEgiH7F5 yVG3i/fAKBNaXwvT6P2Tk7nNH414mwWDQQPebWEq9u4CmuU6lsPf29uOtwCfHNdHAHw5 VSn7BCk4rwZNiNXIioV2A/N28B57Q21ywJh09qKAHUN5M69OictXOkRoLBmt5PtbGxtC ft3w== 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=4gpCZ1HgjbQGL1JUxzN3eohvcZbn2hh+V3Tw9r9L/t0=; b=XgLckcp5ZDQy6R69RAyhjcMBNUmtE0TyMKpcznGJC661eJGTom4Pk6i3dFYKDC8sf+ P+qiouk7vE+6tRtcjRl4mgRKDBf//UWAeXzeHL8Er/cxust0S2IOwb+Mk5mNPrryViA0 2hH+hYqrz85XBMpdLmYSv0SlcZgzD4TGj9bYpcgCRMzpS0+sqT0r0FMwyvKI42v+0ChP +oKyoc/NepzP16NQORpm7BCe2xW92gPx/hK4LbGW07koTLLUb/44QJmSJKjydLHUkZGB MLs7FkR2FIRHZn74p449L5KtVkVqX2TOEmXCl/yUUpyJZk0ZxjtinDDFuy0wm3g+tFQG qNwA== X-Gm-Message-State: AKGB3mJudVpze7vxiWNPptpSpA8P4jYcazPWHSXIExn4NmnlTn9ZfjQa KqMN9Dody3TK+nAtGLRTg1c= X-Google-Smtp-Source: ACJfBosCntnJdexbrsG0dqprGjd0LF50UeeNR8t6b6jYp4hBAl0TFuo9dn9qHw2RiqFvWLJ/eyh/lA== X-Received: by 10.99.168.5 with SMTP id o5mr232248pgf.427.1512996786885; Mon, 11 Dec 2017 04:53:06 -0800 (PST) Received: from localhost.localdomain ([110.70.53.61]) by smtp.gmail.com with ESMTPSA id j13sm23374380pff.131.2017.12.11.04.52.55 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 11 Dec 2017 04:53:05 -0800 (PST) From: Sergey Senozhatsky X-Google-Original-From: Sergey Senozhatsky To: Andrew Morton , Russell King , Catalin Marinas , Mark Salter , Tony Luck , David Howells , Yoshinori Sato , Guan Xuetao , Borislav Petkov , Greg Kroah-Hartman , Thomas Gleixner , Peter Zijlstra , Vineet Gupta , Fengguang Wu Subject: [PATCH 12/13] lib: do not use print_symbol() Date: Mon, 11 Dec 2017 21:50:24 +0900 Message-Id: <20171211125025.2270-13-sergey.senozhatsky@gmail.com> X-Mailer: git-send-email 2.15.1 In-Reply-To: <20171211125025.2270-1-sergey.senozhatsky@gmail.com> References: <20171211125025.2270-1-sergey.senozhatsky@gmail.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20171211_125328_612324_6D0245DC X-CRM114-Status: GOOD ( 10.17 ) X-Spam-Score: -2.0 (--) X-Spam-Report: SpamAssassin version 3.4.1 on casper.infradead.org summary: Content analysis details: (-2.0 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [2607:f8b0:400e:c00:0:0:0:244 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider (sergey.senozhatsky.work[at]gmail.com) -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-snps-arc@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Linux on Synopsys ARC Processors List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Petr Mladek , linux-am33-list@redhat.com, linux-ia64@vger.kernel.org, linux-c6x-dev@linux-c6x.org, linux-sh@vger.kernel.org, x86@kernel.org, Sergey Senozhatsky , LKML , Steven Rostedt , Sergey Senozhatsky , linux-snps-arc@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-edac@vger.kernel.org MIME-Version: 1.0 Sender: "linux-snps-arc" Errors-To: linux-snps-arc-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org print_symbol() uses extra stack space to sprintf() symbol information and then to feed that buffer to printk() char buffer[KSYM_SYMBOL_LEN]; sprint_symbol(buffer, address); printk(fmt, buffer); Replace print_symbol() with a direct printk("%pS") call. Signed-off-by: Sergey Senozhatsky Cc: Andrew Morton Cc: Thomas Gleixner --- lib/smp_processor_id.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/lib/smp_processor_id.c b/lib/smp_processor_id.c index 835cc6df2776..85925aaa4fff 100644 --- a/lib/smp_processor_id.c +++ b/lib/smp_processor_id.c @@ -5,7 +5,6 @@ * DEBUG_PREEMPT variant of smp_processor_id(). */ #include -#include #include notrace static unsigned int check_preemption_disabled(const char *what1, @@ -43,7 +42,7 @@ notrace static unsigned int check_preemption_disabled(const char *what1, printk(KERN_ERR "BUG: using %s%s() in preemptible [%08x] code: %s/%d\n", what1, what2, preempt_count() - 1, current->comm, current->pid); - print_symbol("caller is %s\n", (long)__builtin_return_address(0)); + printk("caller is %pS\n", __builtin_return_address(0)); dump_stack(); out_enable: