From patchwork Mon Aug 3 20:56:14 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Larry Finger X-Patchwork-Id: 6933111 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 16EBB9F6C1 for ; Mon, 3 Aug 2015 20:56:43 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 3B9922041E for ; Mon, 3 Aug 2015 20:56:42 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 5CE1A20414 for ; Mon, 3 Aug 2015 20:56:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755488AbbHCU4j (ORCPT ); Mon, 3 Aug 2015 16:56:39 -0400 Received: from mail-ob0-f171.google.com ([209.85.214.171]:35511 "EHLO mail-ob0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755399AbbHCU4h (ORCPT ); Mon, 3 Aug 2015 16:56:37 -0400 Received: by obbop1 with SMTP id op1so108665415obb.2 for ; Mon, 03 Aug 2015 13:56:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=VeVX4vk2q3uLNlUr4oJYILDUEznoBSANaLXGBQJHUHk=; b=ylUd7y6EPBwmrDJaV005YkDzRH+4uSMUDpTOeniBuLdzioM8D8Uzo+yka8AEsMJezz LB4ol9D0/kL9OrVH8w3SkiSOk1SNyOTczrPlHwwKReP1ZcT2MGvSlzjkPvZeJd4DGHr2 EEy102/tKFQAhJ0LX0i/ZQRmYiL5UAdUgc36ZRE7jU9fzKUMUa+jg8NIq0cN/KABGkkb cjU+1DScdFiXT0hVH9i+xy3mNr9cALVLTN+Fy9LXqWHG4N5mrSi92Hy8UbcQjmSn4ZMH AWb151R3g6fdwL7pkVcAXZEksMxVaniHWj8+78nAGkE5JlsORUAjJHGZYFl6p2/o1xdT Rzgw== X-Received: by 10.60.79.193 with SMTP id l1mr37376oex.60.1438635397076; Mon, 03 Aug 2015 13:56:37 -0700 (PDT) Received: from linux.site (cpe-24-31-249-175.kc.res.rr.com. [24.31.249.175]) by smtp.gmail.com with ESMTPSA id mg19sm7955826oeb.10.2015.08.03.13.56.35 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 03 Aug 2015 13:56:35 -0700 (PDT) From: Larry Finger To: kvalo@codeaurora.org Cc: linux-wireless@vger.kernel.org, Larry Finger Subject: [PATCH NEXT 4/6] rtlwifi: rtl8192de: Fix firmware header endian issues Date: Mon, 3 Aug 2015 15:56:14 -0500 Message-Id: <1438635376-28114-5-git-send-email-Larry.Finger@lwfinger.net> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1438635376-28114-1-git-send-email-Larry.Finger@lwfinger.net> References: <1438635376-28114-1-git-send-email-Larry.Finger@lwfinger.net> Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-5.3 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, UNPARSEABLE_RELAY, URIBL_BLACK autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This driver is converted to use the common firmware header struct. Because the old header definition failed to indicate that the multi-byte entries should be little endian, several problems were thus exposed. These are fixed. Signed-off-by: Larry Finger --- drivers/net/wireless/rtlwifi/rtl8192de/fw.h | 22 ---------------------- 1 file changed, 22 deletions(-) diff --git a/drivers/net/wireless/rtlwifi/rtl8192de/fw.h b/drivers/net/wireless/rtlwifi/rtl8192de/fw.h index 1646e7c..8a38daa 100644 --- a/drivers/net/wireless/rtlwifi/rtl8192de/fw.h +++ b/drivers/net/wireless/rtlwifi/rtl8192de/fw.h @@ -110,28 +110,6 @@ #define SET_H2CCMD_RSVDPAGE_LOC_NULL_DATA(__ph2ccmd, __val) \ SET_BITS_TO_LE_1BYTE((__ph2ccmd) + 2, 0, 8, __val) -struct rtl92d_firmware_header { - u16 signature; - u8 category; - u8 function; - u16 version; - u8 subversion; - u8 rsvd1; - - u8 month; - u8 date; - u8 hour; - u8 minute; - u16 ramcodeSize; - u16 rsvd2; - - u32 svnindex; - u32 rsvd3; - - u32 rsvd4; - u32 rsvd5; -}; - int rtl92d_download_fw(struct ieee80211_hw *hw); void rtl92d_fill_h2c_cmd(struct ieee80211_hw *hw, u8 element_id, u32 cmd_len, u8 *p_cmdbuffer);