From patchwork Tue Mar 2 18:19:10 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Partington X-Patchwork-Id: 46801 X-Patchwork-Delegate: apw@canonical.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from chlorine.canonical.com (chlorine.canonical.com [91.189.94.204]) by ozlabs.org (Postfix) with ESMTP id CD0CEB7CE6 for ; Thu, 4 Mar 2010 00:31:40 +1100 (EST) Received: from localhost ([127.0.0.1] helo=chlorine.canonical.com) by chlorine.canonical.com with esmtp (Exim 4.69) (envelope-from ) id 1Nmofn-0001Ax-0b; Wed, 03 Mar 2010 13:31:35 +0000 Received: from smtprelay0148.hostedemail.com ([216.40.44.148] helo=smtprelay.hostedemail.com) by chlorine.canonical.com with esmtp (Exim 4.69) (envelope-from ) id 1NmWgX-0001ON-NZ for kernel-team@lists.ubuntu.com; Tue, 02 Mar 2010 18:19:09 +0000 Received: from filter.hostedemail.com (ff-bigip1 [10.5.19.254]) by smtprelay02.hostedemail.com (Postfix) with SMTP id 03222112C772; Tue, 2 Mar 2010 18:19:09 +0000 (UTC) X-Panda: scanned! X-Session-Marker: 64617669644070617274696E67746F6E2E636F6D X-Filterd-Recvd-Size: 5401 Received: from [192.168.1.102] (cpe-173-172-70-107.austin.res.rr.com [173.172.70.107]) (Authenticated sender: david@partington.com) by omf05.hostedemail.com (Postfix) with ESMTP; Tue, 2 Mar 2010 18:19:08 +0000 (UTC) Message-ID: <4B8D569E.9080108@partington.com> Date: Tue, 02 Mar 2010 12:19:10 -0600 From: David Partington User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.9pre) Gecko/20100301 Lightning/1.0b1 Shredder/3.0.4pre MIME-Version: 1.0 To: Stefan Bader Subject: Re: [PATCH] hwmon: (it87) Add support for the ITE IT8720F Bug: #357766 References: <4B8807A3.1040400@partington.com> <4B8BC45A.7080007@canonical.com> <4B8BD187.4000000@partington.com> <4B8BD3E9.2070803@canonical.com> <4B8BDCA6.5090709@partington.com> <4B8D199E.7070405@canonical.com> In-Reply-To: <4B8D199E.7070405@canonical.com> X-Mailman-Approved-At: Wed, 03 Mar 2010 13:31:33 +0000 Cc: kernel-team@lists.ubuntu.com X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.9 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kernel-team-bounces@lists.ubuntu.com Errors-To: kernel-team-bounces@lists.ubuntu.com On 03/02/2010 07:58 AM, Stefan Bader wrote: > David Partington wrote: > >> Tim Gardner wrote: >> >>> David Partington wrote: >>> >>> >>>> Tim Gardner wrote: >>>> >>>> >>>>> David Partington wrote: >>>>> >>>>> >>>>> >>>>>> Kernel team: >>>>>> >>>>>> >>>>>> I have a Biostar motherboard with the it8716 superio device. When I >>>>>> execute the sensors hardware monitor the VID values is incorrect, In >>>>>> reviewing the it87.c source I fine the following code burst: >>>>>> >>>>>> >>>>>> >>>>> >>>>> >>>>> Well, you've gotten this far. How about a proper patch? >>>>> >>>>> >>>>> >>>> Tim, >>>> >>>> Thanks for your reply. Actually in the code submitted at the bottom of >>>> my email was the suggested change. However, I did submit an actual >>>> defect report with the suggested fix as well. Please see new defect >>>> #528741. >>>> >>>> Regards, David >>>> >>>> >>>> >>> The code at the bottom of >>> https://lists.ubuntu.com/archives/kernel-team/2010-February/009082.html >>> is not a proper patch wrt the Linux kernel ecosystem. See >>> Documentation/SubmittingPatches in Linus' kernel tree at >>> git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git. >>> >>> The advantage of using diff and patch is the avoidance of transcription >>> errors when applying patches. >>> >>> rtg >>> >>> >> Okay. >> >> I have never submitted a kernel patch before - so you are correct, I >> probably did not follow a recommended procedure. I thought that rather >> than complaining about something that does not work, I endeavored to >> show how to fix the issue. >> >> Regards, David >> >> > Hi David, > > the issue is not so much that you did not follow a procedure, but that you can > help greatly by doing it to get the fix taken forward without needing too much > time and being prone to errors. > If you for the approach have a copy of the file as it is now and one copy of it > as it should be, then a diff -up >mypatch.patch gives you > a file which can be taken an used to make the exact same changes as you did. > Following a textual description, it is just too easy to get things wrong. > > Cheers, > Stefan > > Stephan, Thanks for your reply. I certainly do want to help as much as possible and save time for the team. Per your suggestion I created a diff file to show the suggested changes. This diff file is attached. Regards, David --- it87.c-old 2010-03-02 11:56:04.095882165 -0600 +++ it87.c-new 2010-03-02 12:04:07.837135796 -0600 @@ -1061,7 +1061,7 @@ 1061 1062 if ((sio_data->type == it8718 || sio_data->type == it8720) 1063 && !(sio_data->skip_vid)) -1064 sio_data->vid_value = superio_inb(IT87_SIO_VID_REG); +1064 sio_data->vid_value = superio_inb(IT87_REG_VID); 1065 1066 reg = superio_inb(IT87_SIO_PINX2_REG); 1067 if (reg & (1 << 0)) @@ -1557,10 +1557,10 @@ 1557 1558 data->sensor = it87_read_value(data, IT87_REG_TEMP_ENABLE); 1559 /* The 8705 does not have VID capability. -1560 The 8718 and the 8720 don't use IT87_REG_VID for the +1560 The 8718 and the 8720 don't use IT87_SIO_VID_REG for the 1561 same purpose. */ 1562 if (data->type == it8712 || data->type == it8716) { -1563 data->vid = it87_read_value(data, IT87_REG_VID); +1563 data->vid = it87_read_value(data, IT87_SIO_VID_REG); 1564 /* The older IT8712F revisions had only 5 VID pins, 1565 but we assume it is always safe to read 6 bits. */ 1566 data->vid &= 0x3f;