Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S262929AbVCWVoP (ORCPT ); Wed, 23 Mar 2005 16:44:15 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S262931AbVCWVoP (ORCPT ); Wed, 23 Mar 2005 16:44:15 -0500 Received: from smtp-103-wednesday.noc.nerim.net ([62.4.17.103]:49938 "EHLO mallaury.noc.nerim.net") by vger.kernel.org with ESMTP id S262929AbVCWVoM (ORCPT ); Wed, 23 Mar 2005 16:44:12 -0500 Date: Wed, 23 Mar 2005 22:44:30 +0100 From: Jean Delvare To: Corey Minyard Cc: LKML , LM Sensors , Greg KH Subject: Re: [PATCH] I2C Part 1 - Remove some redundancy from the i2c-core.c file Message-Id: <20050323224430.634e0a75.khali@linux-fr.org> In-Reply-To: <42418B36.5030407@mvista.com> References: <42418B36.5030407@mvista.com> Reply-To: LM Sensors , LKML X-Mailer: Sylpheed version 1.0.3 (GTK+ 1.2.10; i686-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 903 Lines: 24 Hi Corey, > Call i2c_transfer() from i2c_master_send() and i2c_master_recv() > to avoid the redundant code that was in all three functions. I like this. You're right, there is code duplication here, which we can get rid of, so let's do so. I'd only have one comments about your patch: You can get rid of the dev_dbg calls in i2c_master_send() and i2c_master_recv() altogether IMHO. I recently updated i2c_transfer() to make it more verbose in debug mode [1], so the debug messages in i2c_master_send() and i2c_master_recv() are mostly redundant now as far as I can see. [1] http://archives.andrew.net.au/lm-sensors/msg29859.html Thanks, -- Jean Delvare - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/