From patchwork Mon Dec 1 07:17:46 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michal Kazior X-Patchwork-Id: 5410281 Return-Path: X-Original-To: patchwork-ath10k@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id D4199BEEA8 for ; Mon, 1 Dec 2014 07:30:40 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 1639E2027D for ; Mon, 1 Dec 2014 07:30:40 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 34F1320268 for ; Mon, 1 Dec 2014 07:30:39 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1XvLRM-0004nW-AG; Mon, 01 Dec 2014 07:30:36 +0000 Received: from mail-wi0-f175.google.com ([209.85.212.175]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1XvLRJ-0004gJ-DM for ath10k@lists.infradead.org; Mon, 01 Dec 2014 07:30:34 +0000 Received: by mail-wi0-f175.google.com with SMTP id l15so23624807wiw.2 for ; Sun, 30 Nov 2014 23:30:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=tieto.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=UVro2vsYBOs2Zt2ou+1HJfnKpzSzIu0/03/vTGgRguA=; b=QMeb6a8zKnVYrPvdtF11QHeWp1NUTaA5kRuuspEIkiTfDrw1iVfm5Aq/svD70qt4/Y QeeLY86zsXEgrbH8OM9gWZ63xCS93aK09+v7UmfIPpppoZiPOf1hUp/z9alA5WbhwDMA fNhFOhGDL1N0f5w5Jq+WOwdE3czftf5142Vgo= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=UVro2vsYBOs2Zt2ou+1HJfnKpzSzIu0/03/vTGgRguA=; b=B5kOppGqbh0Ybf6CcveQPUzwVvKTansMl+SeoONUyclOaTd/Xrcxo6Lb6sMieVevlW IQO4UbWt1M6XB8cFcTQJSW3cPcqRW1tI5Ga4LPQkDw+kHimLxr0mXY4SoSVCNoSqKt1P 5sMYevXxOgqrYDfb/JJY9+yaABsUoKRhq2R4vIAmgynSl/coEg97Uh6c18Fot9qihZ+e DY3oofCz0EcM25AO/IkZHgOoEP1nSvJyMoUIVdZf8/LGZBd4l36jSeUXyl7967UnpZSE I6UWhowCnZYkt7pg3joG5DbKcISTLKOt6Z9UD+RTMqCdjHZFHCSGExFS6ja0T4RAy0vd KA6Q== X-Gm-Message-State: ALoCoQkbs8ZSX/lnh6wio7PEnywTd/+iqe4ZpYmdpT3sfmUMajZJrhlZxVoTj2eMM080XJ38nYPkneFi3sbxxXHVPPS7yGUcHMrs2RLZrbBs0LczCoFhM+/+ePR9tlGveV6eDmSNTvipBx74A2SKQMKTdCEAn2BKxRnIlvQtSi27alNWIlgab54= X-Received: by 10.194.170.232 with SMTP id ap8mr91248482wjc.2.1417419008394; Sun, 30 Nov 2014 23:30:08 -0800 (PST) Received: from localhost.localdomain ([91.198.246.8]) by mx.google.com with ESMTPSA id fk12sm6676572wic.6.2014.11.30.23.30.07 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 30 Nov 2014 23:30:07 -0800 (PST) From: Michal Kazior To: ath10k@lists.infradead.org Subject: [PATCH v2 3/3] ath10k: move uart pin config into hw_params Date: Mon, 1 Dec 2014 08:17:46 +0100 Message-Id: <1417418266-21974-3-git-send-email-michal.kazior@tieto.com> X-Mailer: git-send-email 1.8.5.3 In-Reply-To: <1417418266-21974-1-git-send-email-michal.kazior@tieto.com> References: <1416838646-18801-1-git-send-email-michal.kazior@tieto.com> <1417418266-21974-1-git-send-email-michal.kazior@tieto.com> X-DomainID: tieto.com X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20141130_233033_664161_E10D61CA X-CRM114-Status: GOOD ( 10.82 ) X-Spam-Score: -0.8 (/) Cc: linux-wireless@vger.kernel.org, Michal Kazior X-BeenThere: ath10k@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "ath10k" Errors-To: ath10k-bounces+patchwork-ath10k=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_LOW, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable 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 will make it possible to easily support different hardware with different uart pin configuration. Signed-off-by: Michal Kazior --- drivers/net/wireless/ath/ath10k/core.c | 3 ++- drivers/net/wireless/ath/ath10k/core.h | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/net/wireless/ath/ath10k/core.c b/drivers/net/wireless/ath/ath10k/core.c index 8bb1657..7c913cc 100644 --- a/drivers/net/wireless/ath/ath10k/core.c +++ b/drivers/net/wireless/ath/ath10k/core.c @@ -48,6 +48,7 @@ static const struct ath10k_hw_params ath10k_hw_params_list[] = { .id = QCA988X_HW_2_0_VERSION, .name = "qca988x hw2.0", .patch_load_addr = QCA988X_HW_2_0_PATCH_LOAD_ADDR, + .uart_pin = 7, .fw = { .dir = QCA988X_HW_2_0_FW_DIR, .fw = QCA988X_HW_2_0_FW_FILE, @@ -698,7 +699,7 @@ static int ath10k_init_uart(struct ath10k *ar) if (!uart_print) return 0; - ret = ath10k_bmi_write32(ar, hi_dbg_uart_txpin, 7); + ret = ath10k_bmi_write32(ar, hi_dbg_uart_txpin, ar->hw_params.uart_pin); if (ret) { ath10k_warn(ar, "could not enable UART prints (%d)\n", ret); return ret; diff --git a/drivers/net/wireless/ath/ath10k/core.h b/drivers/net/wireless/ath/ath10k/core.h index f1a3edd..0188c84 100644 --- a/drivers/net/wireless/ath/ath10k/core.h +++ b/drivers/net/wireless/ath/ath10k/core.h @@ -479,6 +479,7 @@ struct ath10k { u32 id; const char *name; u32 patch_load_addr; + int uart_pin; struct ath10k_hw_params_fw { const char *dir; const char *fw;