Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1306047
| From | Julian Calaby <julian.calaby@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH v3 3/3] checkpatch: add virt barriers |
| Date | 2016-01-11 11:50 +0100 |
| Message-ID | <qPIcW-17S-9@gated-at.bofh.it> (permalink) |
| References | <qPu0h-8t1-9@gated-at.bofh.it> <qPu0h-8t1-17@gated-at.bofh.it> <qPwv7-1M9-7@gated-at.bofh.it> <qPx7P-1Zb-5@gated-at.bofh.it> <qPI3h-13k-59@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Hi Michael,
On Mon, Jan 11, 2016 at 9:35 PM, Michael S. Tsirkin <mst@redhat.com> wrote:
> On Sun, Jan 10, 2016 at 02:52:16PM -0800, Joe Perches wrote:
>> On Mon, 2016-01-11 at 09:13 +1100, Julian Calaby wrote:
>> > On Mon, Jan 11, 2016 at 6:31 AM, Michael S. Tsirkin <mst@redhat.com> wrote:
>> > > Add virt_ barriers to list of barriers to check for
>> > > presence of a comment.
>> []
>> > > diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
>> []
>> > > @@ -5133,7 +5133,8 @@ sub process {
>> > > }x;
>> > > my $all_barriers = qr{
>> > > $barriers|
>> > > - smp_(?:$smp_barrier_stems)
>> > > + smp_(?:$smp_barrier_stems)|
>> > > + virt_(?:$smp_barrier_stems)
>> >
>> > Sorry I'm late to the party here, but would it make sense to write this as:
>> >
>> > (?:smp|virt)_(?:$smp_barrier_stems)
>>
>> Yes. Perhaps the name might be better as barrier_stems.
>>
>> Also, ideally this would be longest match first or use \b
>> after the matches so that $all_barriers could work
>> successfully without a following \s*\(
>>
>> my $all_barriers = qr{
>> (?:smp|virt)_(?:barrier_stems)|
>> $barriers)
>> }x;
>>
>> or maybe add separate $smp_barriers and $virt_barriers
>>
>> <shrug> it doesn't matter much in any case
>
> OK just to clarify - are you OK with merging the patch as is?
> Refactorings can come as patches on top if required.
I don't really care either way, I was just asking if it was possible.
If you don't see any value in that change, then don't make it.
Thanks,
--
Julian Calaby
Email: julian.calaby@gmail.com
Profile: http://www.google.com/profiles/julian.calaby/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH v3 0/3] checkpatch: handling of memory barriers "Michael S. Tsirkin" <mst@redhat.com> - 2016-01-10 20:40 +0100
[PATCH v3 3/3] checkpatch: add virt barriers "Michael S. Tsirkin" <mst@redhat.com> - 2016-01-10 20:40 +0100
Re: [PATCH v3 3/3] checkpatch: add virt barriers Julian Calaby <julian.calaby@gmail.com> - 2016-01-10 23:20 +0100
Re: [PATCH v3 3/3] checkpatch: add virt barriers Joe Perches <joe@perches.com> - 2016-01-11 00:00 +0100
Re: [PATCH v3 3/3] checkpatch: add virt barriers "Michael S. Tsirkin" <mst@redhat.com> - 2016-01-11 11:40 +0100
Re: [PATCH v3 3/3] checkpatch: add virt barriers Julian Calaby <julian.calaby@gmail.com> - 2016-01-11 11:50 +0100
Re: [PATCH v3 3/3] checkpatch: add virt barriers "Michael S. Tsirkin" <mst@redhat.com> - 2016-01-11 12:00 +0100
[PATCH v3 1/3] checkpatch.pl: add missing memory barriers "Michael S. Tsirkin" <mst@redhat.com> - 2016-01-10 20:40 +0100
csiph-web