linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se>
To: Michael Neuling <mikey@neuling.org>
Cc: linuxppc-dev@lists.ozlabs.org, Ian Munsie <imunsie@au1.ibm.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] misc: cxl: sysfs.c: Remove unused function
Date: Sun, 21 Dec 2014 13:46:16 +0100	[thread overview]
Message-ID: <CAFo99ga9TYf5hnwOcoRPKsTHhhknoz6_axzP7spe0mvd=YPMLw@mail.gmail.com> (raw)
In-Reply-To: <1419134735.27324.41.camel@neuling.org>

2014-12-21 5:05 GMT+01:00 Michael Neuling <mikey@neuling.org>:
>> Remove the function mmio_size_show() that is not used anywhere.
>
> Did you compile check this patch?
>
>   drivers/misc/cxl/sysfs.c:291:74: error: =E2=80=98mmio_size_show=E2=80=
=99 undeclared here (not in a function)
>
> It's used here:
>         static struct device_attribute afu_attrs[] =3D {
>                 __ATTR_RO(mmio_size),
>
>> This was partially found by using a static code analysis program called =
cppcheck.
>
> Thanks for letting me know which tool to avoid :-)
>
> Mikey
>
>
>>
>> Signed-off-by: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.=
se>
>> ---
>>  drivers/misc/cxl/sysfs.c |   11 -----------
>>  1 file changed, 11 deletions(-)
>>
>> diff --git a/drivers/misc/cxl/sysfs.c b/drivers/misc/cxl/sysfs.c
>> index ce7ec06..0431ec3 100644
>> --- a/drivers/misc/cxl/sysfs.c
>> +++ b/drivers/misc/cxl/sysfs.c
>> @@ -102,17 +102,6 @@ static struct device_attribute afu_master_attrs[] =
=3D {
>>
>>  /*********  AFU attributes  *******************************************=
*******/
>>
>> -static ssize_t mmio_size_show(struct device *device,
>> -                           struct device_attribute *attr,
>> -                           char *buf)
>> -{
>> -     struct cxl_afu *afu =3D to_cxl_afu(device);
>> -
>> -     if (afu->pp_size)
>> -             return scnprintf(buf, PAGE_SIZE, "%llu\n", afu->pp_size);
>> -     return scnprintf(buf, PAGE_SIZE, "%llu\n", afu->adapter->ps_size);
>> -}
>> -
>>  static ssize_t reset_store_afu(struct device *device,
>>                              struct device_attribute *attr,
>>                              const char *buf, size_t count)
>


Hi

Sorry about that.

Strange because I compile everything as allyesconfig, allmodconfig and
allnoconfig.

Kind regards
Rickard Strandqvist

  reply	other threads:[~2014-12-21 12:46 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-20 16:13 [PATCH] misc: cxl: sysfs.c: Remove unused function Rickard Strandqvist
2014-12-21  4:05 ` Michael Neuling
2014-12-21 12:46   ` Rickard Strandqvist [this message]
2014-12-22  3:55     ` Michael Ellerman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAFo99ga9TYf5hnwOcoRPKsTHhhknoz6_axzP7spe0mvd=YPMLw@mail.gmail.com' \
    --to=rickard_strandqvist@spectrumdigital.se \
    --cc=imunsie@au1.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=mikey@neuling.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).