From patchwork Thu Mar 2 16:38:21 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 9601003 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 94B0A60522 for ; Thu, 2 Mar 2017 16:54:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8444B2858D for ; Thu, 2 Mar 2017 16:54:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 78E7B285B2; Thu, 2 Mar 2017 16:54:24 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.4 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0A25E285A0 for ; Thu, 2 Mar 2017 16:54:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754627AbdCBQts (ORCPT ); Thu, 2 Mar 2017 11:49:48 -0500 Received: from mout.kundenserver.de ([212.227.126.130]:57083 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752574AbdCBQsW (ORCPT ); Thu, 2 Mar 2017 11:48:22 -0500 Received: from wuerfel.lan ([78.42.17.5]) by mrelayeu.kundenserver.de (mreue001 [212.227.15.129]) with ESMTPA (Nemesis) id 0M9S0c-1ca9pL22sY-00Cgh1; Thu, 02 Mar 2017 17:38:53 +0100 From: Arnd Bergmann To: kasan-dev@googlegroups.com Cc: Andrey Ryabinin , Alexander Potapenko , Dmitry Vyukov , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-media@vger.kernel.org, linux-wireless@vger.kernel.org, kernel-build-reports@lists.linaro.org, "David S . Miller" , Arnd Bergmann Subject: [PATCH 13/26] rtl8180: reduce stack size for KASAN Date: Thu, 2 Mar 2017 17:38:21 +0100 Message-Id: <20170302163834.2273519-14-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 In-Reply-To: <20170302163834.2273519-1-arnd@arndb.de> References: <20170302163834.2273519-1-arnd@arndb.de> X-Provags-ID: V03:K0:aXDwrBQPbVnKSDMseDVyo+r1gmmtl5dpPylyTKC2qw8OA/EU1Ay 5VFMT4X/gbliz7zoYoeVIY2HUWmT4F/zw3zPGGmEZF0D+rkmMhUtxbMhZqSaCAGu1iaCHim rTPkek2OaQkhGKdDO6EQIzN4DtTUahOikm1OeByISLCVhK4dEntzJTHUjVEyHtgGWTL9m0h uIypFbafFeWDRdWZifKgw== X-UI-Out-Filterresults: notjunk:1; V01:K0:W6lwtmhMcOs=:9mEsJRUUxSGNukYtU2B0tf y1d+LxLUchdDl9cWP/qbfyv/FAyYXmRL75GgVqHmkRIkTXmx9lkUIp77eqL21ACxzDcHs/afB K5OonGHrF/vfeQszXFQUAKO8jr/npNyLKosyYn9KWpav4GmKYBdrHW6+/jtdcr1rLJM++Hdt6 Hxt4gwrmhdf6g5GwG3LNb3krMxVSPHy7KhIdx+ZRTRjRgEpU2c7g9CWp4h+z8ZcqE58DxvwR2 rKrxwltQYAksB7b1xaiFO2/N2LhWvMad1YeWmq7bYP+M9H5JnWHyh6SyGBUfdyljCX1DiuUpw lSCVyE5uVz0MoG3+14ErPgTbHeCFHfnCkKNeD3/zQX7Mo/tL4O+hh1I9K9k/q9uVFv7vfby97 hrozU4jVk0zQp8soMeGtoQakKpL9qQluvASp/OIdhkecWEWuZhF/HZA2jWKskXaEwb3NwYLdJ ZP+LGYvCdpq7UHlMqvsQiIGz7R37vmCul4Qdc5rzNUB7nBBRR4j/OxKiSLa1fvBxTqO1SS7NS rE/L9+wy5euZkaXO2C8xS0EDocCUthWAHwUXH7DYpXf30jWvD9t8/lz5Pow9P6e89n3WfdPhq iqp1/x6i0/zWXCxhGEB2kGE6eT0tLQqI9N95KT97VuO7lnS1v35mc2eWVGqmUTkdrPXZ9iHiD ev+Don8wqhNwCLqQK4FLz3HxuVPfJj4hBpWwate0M76MT/Z/bnZNutBzlH5Wyxq/IBZE= Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP When CONFIG_KASAN is set, we see overly large stack frames from inlining functions with local variables: drivers/net/wireless/realtek/rtl818x/rtl8180/rtl8225se.c: In function 'rtl8225se_rf_init': drivers/net/wireless/realtek/rtl818x/rtl8180/rtl8225se.c:431:1: warning: the frame size of 4384 bytes is larger than 3072 bytes [-Wframe-larger-than=] This marks them noinline_for_kasan. Signed-off-by: Arnd Bergmann --- drivers/net/wireless/realtek/rtl818x/rtl8180/rtl8225se.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/wireless/realtek/rtl818x/rtl8180/rtl8225se.c b/drivers/net/wireless/realtek/rtl818x/rtl8180/rtl8225se.c index fde89866fa8d..1efa098a2e32 100644 --- a/drivers/net/wireless/realtek/rtl818x/rtl8180/rtl8225se.c +++ b/drivers/net/wireless/realtek/rtl818x/rtl8180/rtl8225se.c @@ -174,14 +174,14 @@ static void rtl8187se_three_wire_io(struct ieee80211_hw *dev, u8 *data, } while (0); } -static u32 rtl8187se_rf_readreg(struct ieee80211_hw *dev, u8 addr) +static noinline_for_kasan u32 rtl8187se_rf_readreg(struct ieee80211_hw *dev, u8 addr) { u32 dataread = addr & 0x0F; rtl8187se_three_wire_io(dev, (u8 *)&dataread, 16, 0); return dataread; } -static void rtl8187se_rf_writereg(struct ieee80211_hw *dev, u8 addr, u32 data) +static noinline_for_kasan void rtl8187se_rf_writereg(struct ieee80211_hw *dev, u8 addr, u32 data) { u32 outdata = (data << 4) | (u32)(addr & 0x0F); rtl8187se_three_wire_io(dev, (u8 *)&outdata, 16, 1);