From patchwork Thu Oct 22 07:49:28 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Holger Schurig X-Patchwork-Id: 55272 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n9M7o1EP022691 for ; Thu, 22 Oct 2009 07:50:01 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752397AbZJVHtz (ORCPT ); Thu, 22 Oct 2009 03:49:55 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752664AbZJVHtz (ORCPT ); Thu, 22 Oct 2009 03:49:55 -0400 Received: from mx51.mymxserver.com ([85.199.173.110]:56355 "EHLO mx51.mymxserver.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752325AbZJVHty (ORCPT ); Thu, 22 Oct 2009 03:49:54 -0400 Received: from localhost (localhost [127.0.0.1]) by localhost.mx51.mymxserver.com (Postfix) with ESMTP id 3D90E5000B; Thu, 22 Oct 2009 09:49:57 +0200 (CEST) X-Virus-Scanned: by Mittwald Mailscanner Received: from mx51.mymxserver.com ([127.0.0.1]) by localhost (mx51.mymxserver.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id UHZ4zJ3ryn9p; Thu, 22 Oct 2009 09:49:57 +0200 (CEST) Received: from lin01.mn-solutions.de (pD95FA7FA.dip0.t-ipconnect.de [217.95.167.250]) by mx51.mymxserver.com (Postfix) with ESMTP id 7BDAC50008; Thu, 22 Oct 2009 09:49:55 +0200 (CEST) Received: by lin01.mn-solutions.de (Postfix, from userid 116) id AC6A41E004F; Thu, 22 Oct 2009 09:49:54 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.1.7-deb3 (2006-10-05) on lin01.mn-logistik.de X-Spam-Level: X-Spam-Status: No, score=-4.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.1.7-deb3 Received: from mnz66.mn-solutions.de (mnz66.mn-solutions.de [192.168.233.66]) by lin01.mn-solutions.de (Postfix) with ESMTP id 641671E0010; Thu, 22 Oct 2009 09:49:45 +0200 (CEST) From: Holger Schurig To: linux-wireless@vger.kernel.org, John Linville , Dan Williams Subject: [PATCH] libertas spi: fix sparse errors Date: Thu, 22 Oct 2009 09:49:28 +0200 User-Agent: KMail/1.9.7 MIME-Version: 1.0 Content-Disposition: inline Message-Id: <200910220949.28773.hs4233@mail.mn-solutions.de> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org --- linux-wl.orig/drivers/net/wireless/libertas/if_spi.c +++ linux-wl/drivers/net/wireless/libertas/if_spi.c @@ -134,7 +134,7 @@ static int spu_write(struct if_spi_card *card, u16 reg, const u8 *buf, int len) { int err = 0; - u16 reg_out = cpu_to_le16(reg | IF_SPI_WRITE_OPERATION_MASK); + __le16 reg_out = cpu_to_le16(reg | IF_SPI_WRITE_OPERATION_MASK); struct spi_message m; struct spi_transfer reg_trans; struct spi_transfer data_trans; @@ -166,7 +166,7 @@ static inline int spu_write_u16(struct if_spi_card *card, u16 reg, u16 val) { - u16 buff; + __le16 buff; buff = cpu_to_le16(val); return spu_write(card, reg, (u8 *)&buff, sizeof(u16)); @@ -188,7 +188,7 @@ { unsigned int delay; int err = 0; - u16 reg_out = cpu_to_le16(reg | IF_SPI_READ_OPERATION_MASK); + __le16 reg_out = cpu_to_le16(reg | IF_SPI_READ_OPERATION_MASK); struct spi_message m; struct spi_transfer reg_trans; struct spi_transfer dummy_trans; @@ -235,7 +235,7 @@ /* Read 16 bits from an SPI register */ static inline int spu_read_u16(struct if_spi_card *card, u16 reg, u16 *val) { - u16 buf; + __le16 buf; int ret; ret = spu_read(card, reg, (u8 *)&buf, sizeof(buf)); @@ -248,7 +248,7 @@ * The low 16 bits are read first. */ static int spu_read_u32(struct if_spi_card *card, u16 reg, u32 *val) { - u32 buf; + __le32 buf; int err; err = spu_read(card, reg, (u8 *)&buf, sizeof(buf));