Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752399AbdGFSEm (ORCPT ); Thu, 6 Jul 2017 14:04:42 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:37461 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751846AbdGFSEk (ORCPT ); Thu, 6 Jul 2017 14:04:40 -0400 Subject: Re: [PATCH 12/18] drivers: s390: Move static and inline before return type To: Heiko Carstens , Joe Perches Cc: Klaus-Dieter Wacker , Andrew Morton , Ursula Braun , Martin Schwidefsky , linux-s390@vger.kernel.org, linux-kernel@vger.kernel.org References: <3f980cd89084ae09716353aba3171e4b3815e690.1499284835.git.joe@perches.com> <20170706102940.GG3217@osiris> <1499338639.19466.25.camel@perches.com> <20170706122539.GJ3217@osiris> From: Julian Wiedmann Date: Thu, 6 Jul 2017 20:04:32 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.1.0 MIME-Version: 1.0 In-Reply-To: <20170706122539.GJ3217@osiris> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-TM-AS-GCONF: 00 x-cbid: 17070618-0016-0000-0000-000004D0ADBD X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17070618-0017-0000-0000-000028041E13 Message-Id: X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-07-06_11:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1703280000 definitions=main-1707060310 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1558 Lines: 41 On 07/06/2017 02:25 PM, Heiko Carstens wrote: > On Thu, Jul 06, 2017 at 03:57:19AM -0700, Joe Perches wrote: >> On Thu, 2017-07-06 at 12:29 +0200, Heiko Carstens wrote: >>> On Wed, Jul 05, 2017 at 01:02:21PM -0700, Joe Perches wrote: >>>> Make the code like the rest of the kernel. >> [] >>>> diff --git a/drivers/s390/net/qeth_l3_main.c b/drivers/s390/net/qeth_l3_main.cqq >> [] >>>> @@ -2408,7 +2408,7 @@ static int qeth_l3_do_ioctl(struct net_device *dev, struct ifreq *rq, int cmd) >>>> return rc; >>>> } >>>> >>>> -int inline qeth_l3_get_cast_type(struct qeth_card *card, struct sk_buff *skb) >>>> +inline int qeth_l3_get_cast_type(struct qeth_card *card, struct sk_buff *skb) >>>> { >>> >>> Actually the function could be made static, and "inline" should be removed, >>> considering the large function body. >> >> I agree to a certain extent. >> >> It's only used once and it looks like Klaus-Dieter Wacker >> just missed adding static to this function. >> >> $ git log --stat -p -1 ce73e10ee0cb6 >> commit ce73e10ee0cb6cde1c5075a2803da0f0eb5b2324 >> Author: Klaus-Dieter Wacker >> >> But it also looks like inline is too often used in several >> drivers/s390/net/*.c files, where most of those static inline >> functions are only used once. >> >> $ git grep -w inline drivers/s390/net/*.c | wc -l >> 42 >> >> Maybe inline removals should be a separate pass for all those. > > Yes, Ursula or Julian can address this if they care. > true, no shortage of inline in s390/net. I'll see about spending a few OCD cycles on it...