From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755285AbaFYIea (ORCPT ); Wed, 25 Jun 2014 04:34:30 -0400 Received: from mail-la0-f47.google.com ([209.85.215.47]:36192 "EHLO mail-la0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753978AbaFYIe1 (ORCPT ); Wed, 25 Jun 2014 04:34:27 -0400 MIME-Version: 1.0 In-Reply-To: <1403682511.17451.21.camel@joe-AO725> References: <1403477209-14612-1-git-send-email-minipli@googlemail.com> <1403477762.18747.14.camel@joe-AO725> <1403505219.18747.37.camel@joe-AO725> <87egyeqt03.fsf@rasmusvillemoes.dk> <1403638620.29061.35.camel@joe-AO725> <1403641843.29061.51.camel@joe-AO725> <1403643440.29061.56.camel@joe-AO725> <1403646310.29061.61.camel@joe-AO725> <877g45qw53.fsf@rasmusvillemoes.dk> <1403682511.17451.21.camel@joe-AO725> Date: Wed, 25 Jun 2014 10:34:25 +0200 Message-ID: Subject: Re: [RFC PATCH 0/3] Mark literal strings in __init / __exit code From: Mathias Krause To: Joe Perches Cc: Rasmus Villemoes , "linux-kernel@vger.kernel.org" , Andrew Morton , Greg Kroah-Hartman , Steven Rostedt , "Rafael J. Wysocki" , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 25 June 2014 09:48, Joe Perches wrote: > On Wed, 2014-06-25 at 09:35 +0200, Rasmus Villemoes wrote: >> Speaking of dangling pointers: A similar disaster would happen if some >> code containing pi_* calls gets copy-pasted to some non-__init >> function. > > This is my biggest issue with adding these new, > somewhat obscure macros. modpost will handle these cases. >> Could checkpatch learn to warn about calling these functions >> from the wrong context? > > It's not possible. checkpatch works on patch chunks. > Any patch chunk may not contain the function attributes. checkpatch.pl -f might detect them, though :/ Thanks, Mathias