Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752969Ab1FNRmm (ORCPT ); Tue, 14 Jun 2011 13:42:42 -0400 Received: from mail-bw0-f46.google.com ([209.85.214.46]:52334 "EHLO mail-bw0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751433Ab1FNRmk (ORCPT ); Tue, 14 Jun 2011 13:42:40 -0400 DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=from:to:subject:date:user-agent:cc:references:in-reply-to :mime-version:content-type:content-transfer-encoding:message-id; b=OzvTLMyICqMUNxnnEFHkVya0awUba9mgR86X/fqN0A8Fh9peqMUoqn3FbijocJLeaO 9v5/Oeh88DMhA3G1Dp7QFSUz/01DWYW1GWZz/tpB0GEwrG5sARnUi8szx/2/qKsHRR4O WwyhXi/LyrHWRi9FOE29rordaGzOnhSvQAtHI= From: Christian Lamparter To: Joe Perches Subject: Re: [ath9k-devel] [PATCH net-next 1/2] wireless: Remove casts of void * Date: Tue, 14 Jun 2011 19:43:15 +0200 User-Agent: KMail/1.13.5 (Linux/3.0.0-rc2-wl+; KDE/4.4.5; x86_64; ; ) Cc: Pavel Roskin , netdev@vger.kernel.org, Intel Linux Wireless , linux-kernel@vger.kernel.org, linux-wireless@vger.kernel.org, "John W. Linville" , Jouni Malinen , Senthil Balasubramanian , ath9k-devel@venema.h4ckr.net, "Wey-Yi Guy" , Vasanthakumar Thiagarajan , Stanislaw Gruszka References: <4DF78CEC.70409@gnu.org> <1308069831.21026.9.camel@Joe-Laptop> In-Reply-To: <1308069831.21026.9.camel@Joe-Laptop> MIME-Version: 1.0 Content-Type: Text/Plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <201106141943.15887.chunkeey@googlemail.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1331 Lines: 34 On Tuesday 14 June 2011 18:43:51 Joe Perches wrote: > On Tue, 2011-06-14 at 12:31 -0400, Pavel Roskin wrote: > > On 06/14/2011 12:02 AM, Joe Perches wrote: > > > /* Get the message ID */ > > > - msg_id = (__be16 *) ((void *) htc_hdr + > > > - sizeof(struct htc_frame_hdr)); > > > + msg_id = (void *)htc_hdr + sizeof(struct htc_frame_hdr); > > I would never do stuff like this without verifying by sparse that no > > warnings are introduced. > > I did that. I believe there are no new warnings. > > > Sparse warnings should be avoided to keep sparse checks useful. > > Otherwise, important warnings would drown in the noise. > > $ make allyesconfig > $ git log -1 --pretty=oneline drivers/net/wireless/ath/ath9k/htc_hst.c > 337c22b774ff7f007b90b266b25c9a33ff555c48 wireless: Remove casts of void * > $ make C=2 drivers/net/wireless/ath/ath9k/htc_hst.o Just a quick FYI: To perform endianness checks, you may define __CHECK_ENDIAN__: make C=2 CF="-D__CHECK_ENDIAN__" [Although, it doesn't look like your patch introduced any new endianness problems] Regards, Chr -- 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/