public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: "weiyongjun (A)" <weiyongjun1@huawei.com>
To: Ye Bin <yebin10@huawei.com>,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: <linuxppc-dev@lists.ozlabs.org>, <linux-kernel@vger.kernel.org>,
	<kernel-janitors@vger.kernel.org>, Hulk Robot <hulkci@huawei.com>
Subject: Re: [PATCH -next] [POWERPC] Rename get_property to of_get_property: use DEFINE_SPINLOCK() for spinlock
Date: Fri, 9 Apr 2021 17:52:55 +0800	[thread overview]
Message-ID: <f63e20d1-7161-bb54-35cb-877ee747acaa@huawei.com> (raw)
In-Reply-To: <4b0b16f3-bb06-3a90-5148-ea8302bb3a58@huawei.com>


Rename get_property to of_get_property: use DEFINE_SPINLOCK() for spinlock

^^^^^^^^^

Please fix the module name in the patch subject.


> spinlock can be initialized automatically with DEFINE_SPINLOCK()
>
>> rather than explicitly calling spin_lock_init().
>>
>> Reported-by: Hulk Robot <hulkci@huawei.com>
>> Signed-off-by: Ye Bin <yebin10@huawei.com>
>> ---
>>   drivers/macintosh/via-pmu-led.c | 4 +---
>>   1 file changed, 1 insertion(+), 3 deletions(-)
>>
>> diff --git a/drivers/macintosh/via-pmu-led.c 
>> b/drivers/macintosh/via-pmu-led.c
>> index ae067ab2373d..2502119cff42 100644
>> --- a/drivers/macintosh/via-pmu-led.c
>> +++ b/drivers/macintosh/via-pmu-led.c
>> @@ -27,7 +27,7 @@
>>   #include <linux/pmu.h>
>>   #include <asm/prom.h>
>>   -static spinlock_t pmu_blink_lock;
>> +static DEFINE_SPINLOCK(pmu_blink_lock);
>>   static struct adb_request pmu_blink_req;
>>   /* -1: no change, 0: request off, 1: request on */
>>   static int requested_change;
>> @@ -105,8 +105,6 @@ static int __init via_pmu_led_init(void)
>>           return -ENODEV;
>>       }
>>       of_node_put(dt);
>> -
>> -    spin_lock_init(&pmu_blink_lock);
>>       /* no outstanding req */
>>       pmu_blink_req.complete = 1;
>>       pmu_blink_req.done = pmu_req_done;
>>

      reply	other threads:[~2021-04-09  9:53 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-09  9:51 [PATCH -next] [POWERPC] Rename get_property to of_get_property: use DEFINE_SPINLOCK() for spinlock Ye Bin
2021-04-09  9:47 ` weiyongjun (A)
2021-04-09  9:52   ` weiyongjun (A) [this message]

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=f63e20d1-7161-bb54-35cb-877ee747acaa@huawei.com \
    --to=weiyongjun1@huawei.com \
    --cc=benh@kernel.crashing.org \
    --cc=hulkci@huawei.com \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=yebin10@huawei.com \
    /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