From patchwork Fri Sep 23 19:13:35 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Vasut X-Patchwork-Id: 116170 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 5B62E1007D3 for ; Sat, 24 Sep 2011 05:13:53 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id A99312867E; Fri, 23 Sep 2011 21:13:51 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id K+nVCDTeT5Cx; Fri, 23 Sep 2011 21:13:51 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 3744E28681; Fri, 23 Sep 2011 21:13:49 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id E079428681 for ; Fri, 23 Sep 2011 21:13:46 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 6Q6VWg9u64wc for ; Fri, 23 Sep 2011 21:13:44 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mail-bw0-f44.google.com (mail-bw0-f44.google.com [209.85.214.44]) by theia.denx.de (Postfix) with ESMTPS id CF5C62867E for ; Fri, 23 Sep 2011 21:13:43 +0200 (CEST) Received: by bkaq10 with SMTP id q10so3643338bka.3 for ; Fri, 23 Sep 2011 12:13:43 -0700 (PDT) Received: by 10.223.57.70 with SMTP id b6mr5586186fah.124.1316805220331; Fri, 23 Sep 2011 12:13:40 -0700 (PDT) Received: from mashiro.ms.mff.cuni.cz (eduroam32.ms.mff.cuni.cz. [195.113.21.32]) by mx.google.com with ESMTPS id j5sm9901104fac.25.2011.09.23.12.13.39 (version=SSLv3 cipher=OTHER); Fri, 23 Sep 2011 12:13:40 -0700 (PDT) From: Marek Vasut To: u-boot@lists.denx.de Date: Fri, 23 Sep 2011 21:13:35 +0200 Message-Id: <1316805216-26435-1-git-send-email-marek.vasut@gmail.com> X-Mailer: git-send-email 1.7.5.4 Subject: [U-Boot] [PATCH] ASIX: Fix buffer access in asix_get_phy_addr() X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.9 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de Signed-off-by: Marek Vasut --- drivers/usb/eth/asix.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/usb/eth/asix.c b/drivers/usb/eth/asix.c index 9b012e4..2f116c0 100644 --- a/drivers/usb/eth/asix.c +++ b/drivers/usb/eth/asix.c @@ -219,7 +219,7 @@ static inline int asix_get_phy_addr(struct ueth_data *dev) debug("Error reading PHYID register: %02x\n", ret); goto out; } - debug("asix_get_phy_addr() returning 0x%04x\n", *((__le16 *)buf)); + debug("asix_get_phy_addr() returning 0x%02x%02x\n", buf[0], buf[1]); ret = buf[1]; out: