From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753705AbaCEFfW (ORCPT ); Wed, 5 Mar 2014 00:35:22 -0500 Received: from nm7-vm4.bullet.mail.gq1.yahoo.com ([98.136.218.211]:25132 "EHLO nm7-vm4.bullet.mail.gq1.yahoo.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753430AbaCEFfT convert rfc822-to-8bit (ORCPT ); Wed, 5 Mar 2014 00:35:19 -0500 X-Yahoo-Newman-Property: ymail-3 X-Yahoo-Newman-Id: 804556.72464.bm@omp1001.mail.gq1.yahoo.com DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:X-Rocket-MIMEInfo:X-Mailer:References:Message-ID:Date:From:Reply-To:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=De/JBBAy/ASxyxKpD48yaDzLyyPhNVb9qB9dclSHUxAbHp4XvsQLktpW2npskky0hn9r3vayklwy4Qm5VHgW9eSdnUcBeZSItBoNS3AyEL6KM4QpKba/duz3UzRxZtxe7nVEHd3bbUpfK9c/92nkmk0m4g7MwZfmihNv3X2PiK4=; X-YMail-OSG: QJJsEMwVM1mNUfsT3mhOjzEhk5XNMJWbZQvjJSDswZ8Gv7h gwyvh2Be_JGyGVt7w0n0zbPsM217CFF2t41Ju.5areRXaAZU2YWCbPNxrqKC kA.DVPsZ8fVmMhJ3JZfasH_aIXVvDWJBVbOYpFw.EVHKZyfSO3IuWDdDbKe6 B9Or7d0qx8GHb1aWxqg3UBY_pLvgOLA9kLsSr2pNWVdrC369obDeBqIBpPOx 7LJtRc_xeGm0X9MACVj_AXG_4J2NQWqzq0NOL3Hmoaguz1PkFQyUz5NHT5h3 4hPZdTR22QJtiys23kW0DYWn1r6uz9R8si.hgnFy9cs2bznnePIjkeqYvdka IWMJne00HTQSYOIZJiazaV9mla91RGZwEVkOkPyjI2.yGItorsmETXWHpFbL LiaVZxmM_HI3Esxp7D4VEoDHQg.2yp2_SQmbXnL_UOby5.q6Hf89aG1XORy_ uyMzfUq.s25P4auyUcCi_37rcjn5U_YdRkcfvchM0zoB3UCnf41.nJiEjdp_ Ki1y.URdqu_WqgEkH6_mLdgMW2Ohs1IU- X-Rocket-MIMEInfo: 002.001,Pk9uIFR1ZXNkYXksIE1hcmNoIDQsIDIwMTQgNjozOCBQTSwgR3JlZyBLSCA8Z3JlZ2toQGxpbnV4Zm91bmRhdGlvbi5vcmc.IHdyb3RlOgoKPj5PbiBNb24sIE1hciAwMywgMjAxNCBhdCAxMjoyNzo1NVBNICswMzAwLCBEYW4gQ2FycGVudGVyIHdyb3RlOgo.Pj4gT24gU3VuLCBNYXIgMDIsIDIwMTQgYXQgMDg6NTI6MTlQTSAtMDYwMCwgQ2hhc2UgU291dGh3b29kIHdyb3RlOgo.Pj4gVGhpcyBwYXRjaCBpbnRyb2R1Y2VzIGEgZmV3IHNpbXBsZSBvdXRsIGFuZCBpbmwgaGVscGVyIGZ1bmN0aW9ucyB0byBhbGwBMAEBAQE- X-Mailer: YahooMailWebService/0.8.177.636 References: <1393669707-20107-1-git-send-email-chase.southwood@yahoo.com> <1393815139-10663-1-git-send-email-chase.southwood@yahoo.com> <20140303092755.GD27552@mwanda> <20140305003943.GA1286@kroah.com> Message-ID: <1393997718.25929.YahooMailNeo@web164002.mail.gq1.yahoo.com> Date: Tue, 4 Mar 2014 21:35:18 -0800 (PST) From: Chase Southwood Reply-To: Chase Southwood Subject: Re: [PATCH v2 1/2] Staging: comedi: introduce {outl,inl}_amcc() and {outl,inl}_iobase() helper functions in hwdrv_apci1564.c To: Greg KH , Dan Carpenter Cc: "devel@driverdev.osuosl.org" , "abbotti@mev.co.uk" , "linux-kernel@vger.kernel.org" In-Reply-To: <20140305003943.GA1286@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org >On Tuesday, March 4, 2014 6:38 PM, Greg KH wrote: >>On Mon, Mar 03, 2014 at 12:27:55PM +0300, Dan Carpenter wrote: >>> On Sun, Mar 02, 2014 at 08:52:19PM -0600, Chase Southwood wrote: >>> This patch introduces a few simple outl and inl helper functions to allow >>> several lines which violate the character limit to be shortened >>> appropriately.  It also changes a few macro values which represented >>> offset values from a single unique base value to instead represent the value >>> of that base plus the offset.  This is to simplify the use of these macros >>> in the new helper functions. >>> >>> Cc: Dan Carpenter >>> Signed-off-by: Chase Southwood >>> --- >>> >>> All right, here's another shot at this.  Dan, I took your outl_amcc idea >>> and did a version for the outl/inl calls based from devpriv->iobase as well. >>> I changed all of the macros which only offset from one base value as you >>> had mentioned as well, and the result is starting to look very good. >>> The only outl/inl calls which still look a little gross (see PATCH v2 2/2) are >>> the ones involving DIGITAL_OP_WATCHDOG, TIMER, or any of the COUNTER macros, >>> just because they use a common set of offset macros so simplifying >>> those calls in the same way as the rest isn't possible.  What are your >>> thoughts on this version of the patchset? >>> >>> This is version 2 of [PATCH 1/2] Staging: comedi: introduce outl_1564_* and >>> inl_1564_* helper functions in hwdrv_apci1564.c >>> >>> 2: Changed helper functions from {outl,inl}_1564_*() to >>> {outl,inl}_{amcc,iobase}() >>> >>> Comments welcome! >>> >>>  .../comedi/drivers/addi-data/hwdrv_apci1564.c      | 38 +++++++++++++++++----- >>>  1 file changed, 30 insertions(+), 8 deletions(-) >>> >>> diff --git a/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c b/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c >>> index 2b47fa1..58e301d 100644 >>> --- a/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c >>> +++ b/drivers/staging/comedi/drivers/addi-data/hwdrv_apci1564.c >>> @@ -49,25 +49,25 @@ This program is distributed in the hope that it will be useful, but WITHOUT ANY >>>  /* DIGITAL INPUT-OUTPUT DEFINE */ >>>  /* Input defines */ >>>  #define APCI1564_DIGITAL_IP                0x04 >>> -#define APCI1564_DIGITAL_IP_INTERRUPT_MODE1        4 >>> -#define APCI1564_DIGITAL_IP_INTERRUPT_MODE2        8 >>> -#define APCI1564_DIGITAL_IP_IRQ                16 >>> +#define APCI1564_DIGITAL_IP_INTERRUPT_MODE1        (0x04 + 0x04) >>> +#define APCI1564_DIGITAL_IP_INTERRUPT_MODE2        (0x04 + 0x08) >>> +#define APCI1564_DIGITAL_IP_IRQ                (0x04 + 0x10) >>  >> You can't change these without changing the callers.  This bit needs to >> be in patch 2/2.  You should probably just merge both patches anyway >> because presumably this one adds some GCC warnings about unused static >> functions.> > >I'm totally confused about this series... > >Chase, can you resend any outstanding patches that I haven't applied of >yours, as these different revisions and threads don't make much sense >right now. > Greg, Yes, admittedly this whole thing has gotten a little messy :P sorry for all the confusion. I've finally spoken with Hartley about how to best clean this driver, and so I will submit a final patchset to you as soon as I finish up with it.  Until then, please just disregard all prior patches to hwdrv_apci1564.c from me, as the one I send next will supersede all of them and I will clearly mark it as such for you. Thanks, Chase > >thanks, > >greg k-h