From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julia Lawall Subject: Re: [PATCH v3 0/5] bq27xxx_battery data memory update Date: Sun, 1 Oct 2017 13:59:45 +0200 (CEST) Message-ID: References: <20170824033617.20840-1-liam@networkimprov.net> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Return-path: Received: from mail3-relais-sop.national.inria.fr ([192.134.164.104]:11030 "EHLO mail3-relais-sop.national.inria.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750965AbdJAL7r (ORCPT ); Sun, 1 Oct 2017 07:59:47 -0400 In-Reply-To: Sender: linux-pm-owner@vger.kernel.org List-Id: linux-pm@vger.kernel.org To: Liam Breck Cc: Sebastian Reichel , Gilles Muller , Nicolas Palix , Michal Marek , cocci@systeme.lip6.fr, "Andrew F. Davis" , =?ISO-8859-15?Q?Pali_Roh=E1r?= , Linux PM mailing list On Wed, 27 Sep 2017, Liam Breck wrote: > On Wed, Sep 27, 2017 at 5:16 AM, Julia Lawall wrote: > > > > > > On Wed, 27 Sep 2017, Liam Breck wrote: > > > >> Hi Julia, thanks so much for your help! > >> > >> On Wed, Sep 27, 2017 at 3:02 AM, Julia Lawall wrote: > >> > The github version of Coccinelle finally supports the semantic patch for > >> > your code. I have attached the semantic patch. I wonder what should be > >> > done with this? Do you want to use it locally with make coccicheck? Do > >> > you want it to be integrated into the kernel? Everything in the semantic > >> > >> Yes, our intent is to push it upstream. Can you submit a patch? > >> > >> Did you test with 4.13? That should show a handful of dupes... > > > > Are you sure? I did a git checkout v4.13 and there aren't any occurrences > > of BQ27XXX_DATA. > > Sorry, that macro landed in 4.14. If you revert this commit, you > should see dupes: > power: supply: bq27xxx: Remove duplicate chip data arrays Thanks for the pointer to this commit. I get the results described in the commit log: bq27500_regs and bq27510g1_regs have the same registers bq27500_regs and bq27510g2_regs have the same registers bq27510g1_regs and bq27510g2_regs have the same registers bq27510g3_regs and bq2751x_regs have the same registers bq2750x_props and bq27510g3_props have the same properties bq2750x_props and bq2751x_props have the same properties bq27510g3_props and bq2751x_props have the same properties bq27500_props and bq27510g1_props have the same properties bq27500_props and bq27510g2_props have the same properties bq27500_props and bq27520g2_props have the same properties bq27510g1_props and bq27510g2_props have the same properties bq27510g1_props and bq27520g2_props have the same properties bq27510g2_props and bq27520g2_props have the same properties julia From mboxrd@z Thu Jan 1 00:00:00 1970 From: julia.lawall@lip6.fr (Julia Lawall) Date: Sun, 1 Oct 2017 13:59:45 +0200 (CEST) Subject: [Cocci] [PATCH v3 0/5] bq27xxx_battery data memory update In-Reply-To: References: <20170824033617.20840-1-liam@networkimprov.net> Message-ID: To: cocci@systeme.lip6.fr List-Id: cocci@systeme.lip6.fr On Wed, 27 Sep 2017, Liam Breck wrote: > On Wed, Sep 27, 2017 at 5:16 AM, Julia Lawall wrote: > > > > > > On Wed, 27 Sep 2017, Liam Breck wrote: > > > >> Hi Julia, thanks so much for your help! > >> > >> On Wed, Sep 27, 2017 at 3:02 AM, Julia Lawall wrote: > >> > The github version of Coccinelle finally supports the semantic patch for > >> > your code. I have attached the semantic patch. I wonder what should be > >> > done with this? Do you want to use it locally with make coccicheck? Do > >> > you want it to be integrated into the kernel? Everything in the semantic > >> > >> Yes, our intent is to push it upstream. Can you submit a patch? > >> > >> Did you test with 4.13? That should show a handful of dupes... > > > > Are you sure? I did a git checkout v4.13 and there aren't any occurrences > > of BQ27XXX_DATA. > > Sorry, that macro landed in 4.14. If you revert this commit, you > should see dupes: > power: supply: bq27xxx: Remove duplicate chip data arrays Thanks for the pointer to this commit. I get the results described in the commit log: bq27500_regs and bq27510g1_regs have the same registers bq27500_regs and bq27510g2_regs have the same registers bq27510g1_regs and bq27510g2_regs have the same registers bq27510g3_regs and bq2751x_regs have the same registers bq2750x_props and bq27510g3_props have the same properties bq2750x_props and bq2751x_props have the same properties bq27510g3_props and bq2751x_props have the same properties bq27500_props and bq27510g1_props have the same properties bq27500_props and bq27510g2_props have the same properties bq27500_props and bq27520g2_props have the same properties bq27510g1_props and bq27510g2_props have the same properties bq27510g1_props and bq27520g2_props have the same properties bq27510g2_props and bq27520g2_props have the same properties julia