From patchwork Thu Feb 19 09:13:20 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?QW50dGkgU2VwcMOkbMOk?= X-Patchwork-Id: 5850701 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 7BA1ABF440 for ; Thu, 19 Feb 2015 09:13:48 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id A3DAC20295 for ; Thu, 19 Feb 2015 09:13:47 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id C08F220272 for ; Thu, 19 Feb 2015 09:13:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752165AbbBSJNn (ORCPT ); Thu, 19 Feb 2015 04:13:43 -0500 Received: from mail-lb0-f178.google.com ([209.85.217.178]:44498 "EHLO mail-lb0-f178.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751945AbbBSJNl (ORCPT ); Thu, 19 Feb 2015 04:13:41 -0500 Received: by lbiz12 with SMTP id z12so6235510lbi.11 for ; Thu, 19 Feb 2015 01:13:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:mime-version:content-type :content-transfer-encoding; bh=Nc8O5tyhcmS17RK69I28RKDK/jY/4jPm5FiKOxcW5nQ=; b=KgudIKtVMM/gwQEJkEmIJXgkW5kockrdMrJjQbsTLd1Vcn6j0XPWPLInhkdDLIABOK 9l701Srex7U/5AfPDne6o5J+/MTowoHkv8Yocno47myDItaxzdsMsNhrpJdpBWptYQFe kFBkENg3em3KzvtD16zQThjVS51KeYv7zrUh3BOgz+4iA7eFY2dkrwT9WOKdZdx8gtn4 v/WaP0yVRQ0T/XUB92aqXxQVmTHrNvFcAx85rcJy9h/bC0mOfX/oTxGKxLNAEp+RDxCo xre/447HkFxOSW03/5mxKGxvfZCuqJ2BQ2n6I04ZSK18WgTaJHRa0/NlAMpRBvuW/DI5 jDXQ== X-Received: by 10.112.142.134 with SMTP id rw6mr3128800lbb.100.1424337220187; Thu, 19 Feb 2015 01:13:40 -0800 (PST) Received: from pixie.elisa-laajakaista.fi (a91-154-178-36.elisa-laajakaista.fi. [91.154.178.36]) by mx.google.com with ESMTPSA id i13sm3998202lab.38.2015.02.19.01.13.38 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 19 Feb 2015 01:13:39 -0800 (PST) From: =?UTF-8?q?Antti=20Sepp=C3=A4l=C3=A4?= To: Antti Palosaari Cc: linux-media@vger.kernel.org, =?UTF-8?q?Antti=20Sepp=C3=A4l=C3=A4?= Subject: [RFC PATCH] mn88472: reduce firmware download chunk size Date: Thu, 19 Feb 2015 11:13:20 +0200 Message-Id: <1424337200-6446-1-git-send-email-a.seppala@gmail.com> X-Mailer: git-send-email 2.0.5 MIME-Version: 1.0 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, 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 It seems that currently the firmware download on the mn88472 is somehow wrong for my Astrometa HD-901T2. Reducing the download chunk size (mn88472_config.i2c_wr_max) to 2 makes the firmware download consistently succeed. Any larger value causes the download to always fail: [ 7.671482] mn88472 7-0018: downloading firmware from file 'dvb-demod-mn88472-02.fw' [ 8.206960] mn88472 7-0018: firmware download failed=-32 [ 8.208610] rtl2832 7-0010: i2c reg write failed -32 [ 8.208620] r820t 8-003a: r820t_write: i2c wr failed=-32 reg=05 len=1: 83 [ 8.210459] rtl2832 7-0010: i2c reg write failed -32 [ 8.212038] rtl2832 7-0010: i2c reg write failed -32 I'm obviously not too happy about this patch as it slows down the firmware download but I have not found a way to keep larger chunks in place and have a working firmware download at the same time. Signed-off-by: Antti Seppälä --- drivers/media/usb/dvb-usb-v2/rtl28xxu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/usb/dvb-usb-v2/rtl28xxu.c b/drivers/media/usb/dvb-usb-v2/rtl28xxu.c index d88f799..3c5c6f9 100644 --- a/drivers/media/usb/dvb-usb-v2/rtl28xxu.c +++ b/drivers/media/usb/dvb-usb-v2/rtl28xxu.c @@ -865,7 +865,7 @@ static int rtl2832u_frontend_attach(struct dvb_usb_adapter *adap) struct mn88472_config mn88472_config = {}; mn88472_config.fe = &adap->fe[1]; - mn88472_config.i2c_wr_max = 22, + mn88472_config.i2c_wr_max = 2, strlcpy(info.type, "mn88472", I2C_NAME_SIZE); mn88472_config.xtal = 20500000; info.addr = 0x18;