From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-13.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2AAB5C4338F for ; Wed, 25 Aug 2021 13:47:24 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 5BC32610D2 for ; Wed, 25 Aug 2021 13:47:23 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 5BC32610D2 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=nic.cz Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 63EBA82F0C; Wed, 25 Aug 2021 15:47:00 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=nic.cz Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; secure) header.d=nic.cz header.i=@nic.cz header.b="fIEh3cXm"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 1B9BD82986; Wed, 25 Aug 2021 15:46:45 +0200 (CEST) Received: from mail.nic.cz (mail.nic.cz [217.31.204.67]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 64E6582D5B for ; Wed, 25 Aug 2021 15:46:35 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=nic.cz Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=marek.behun@nic.cz Received: from dellmb.labs.office.nic.cz (unknown [IPv6:2001:1488:fffe:6:8747:7254:5571:3010]) by mail.nic.cz (Postfix) with ESMTPSA id C20EE13FB72; Wed, 25 Aug 2021 15:46:34 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=nic.cz; s=default; t=1629899194; bh=FCcLN4IaQ6qYpQ78hXDlzSJamjW+h+bxNwJPs7ZDgsM=; h=From:To:Date; b=fIEh3cXmfe0lGggG+Zwn7VYK8WPE8isXBr3gPJs5Dv9edRLcLRv6rkBvGtXmITuE9 p28Em5ehY13uGgKz2894aocuKw9yQcwqZOsulhIiimp2t5l8iJGoM8u+rn4WpL6D1u fc13Ya0Xm8wvoN4gThE/mrAYCeAgnjvfnNHYxuDA= From: =?UTF-8?q?Marek=20Beh=C3=BAn?= To: Stefan Roese Cc: u-boot@lists.denx.de, pali@kernel.org, Chris Packham , Baruch Siach , Dennis Gilmore , Mario Six , Jon Nettleton , =?UTF-8?q?Marek=20Beh=C3=BAn?= Subject: [PATCH u-boot-marvell 00/29] kwboot higher baudrate Date: Wed, 25 Aug 2021 15:46:05 +0200 Message-Id: <20210825134634.3959-1-marek.behun@nic.cz> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean Hello Stefan and others, this series adds support for booting Marvell platforms via UART (those bootable with kwboot) at higher baudrates. Tested on Turris Omnia up to 5.15 MBd, which is 44x faster than 115200 Bd. The user can direct kwboot to use higher baudrate via the -B option. (BTW this option was there before but did not work with the -b option.) Only the payload part of the KWB image is uploaded at this higher baudrate. The header part is still uploaded at 115200 Bd, since the code that changes baudrate is injected into header as a binary extension. (The payload part makes up majority of the binary, though. On Turris Omnia the payload currently makes ~87%.) The series also contains various other fixes, refactors and improvements of the code, upon which the main change is done. Marek & Pali Marek Behún (13): tools: kwbimage: Fix printf format warning tools: kwboot: Fix buffer overflow in kwboot_terminal() tools: kwboot: Make the quit sequence buffer const tools: kwboot: Refactor and fix writing buffer tools: kwboot: Fix comparison of integers with different size tools: kwboot: Use a function to check whether received byte is a Xmodem reply tools: kwboot: Print new line after SPL output tools: kwboot: Allow greater timeout when executing header code tools: kwbimage: Simplify iteration over version 1 optional headers tools: kwbimage: Refactor image_version() tools: kwbimage: Refactor kwbimage header size determination doc/kwboot.1: Update man page MAINTAINERS: Add entry for kwbimage / kwboot tools Pali Rohár (16): tools: kwboot: Print version information header tools: kwboot: Fix kwboot_xm_sendblock() function when kwboot_tty_recv() fails tools: kwboot: Fix return type of kwboot_xm_makeblock() function tools: kwboot: Fix printing progress tools: kwboot: Print newline on error when progress was not completed tools: kwboot: Split sending image into header and data stages tools: kwboot: Allow non-xmodem text output from BootROM only in a specific case tools: kwboot: Properly finish xmodem transfer tools: kwboot: Always call kwboot_img_patch_hdr() tools: kwboot: Don't patch image header if signed tools: kwboot: Patch source address in image header tools: kwboot: Patch destination address to DDR area for SPI image tools: kwboot: Round up header size to 128 B when patching tools: kwboot: Support higher baudrates when booting via UART tools: kwboot: Allow any baudrate on Linux tools: kwboot: Add Pali and Marek as authors MAINTAINERS | 10 + doc/kwboot.1 | 58 ++- tools/kwbimage.c | 127 ++--- tools/kwbimage.h | 93 +++- tools/kwboot.c | 1103 +++++++++++++++++++++++++++++++++++------ tools/termios_linux.h | 170 +++++++ 6 files changed, 1289 insertions(+), 272 deletions(-) create mode 100644 tools/termios_linux.h -- 2.31.1