diff options
author | Petr Vaněk <arkamar@gentoo.org> | 2024-09-08 21:37:47 +0200 |
---|---|---|
committer | Petr Vaněk <arkamar@gentoo.org> | 2024-09-08 21:55:46 +0200 |
commit | b889a401a8a2206855f053234df27195315871e8 (patch) | |
tree | 525a48fb7c519bee461abff0306c46aa2392b406 /dev-embedded | |
parent | media-gfx/imagemagick: Revert some upstream changes to Perl build system (diff) | |
download | gentoo-b889a401a8a2206855f053234df27195315871e8.tar.gz gentoo-b889a401a8a2206855f053234df27195315871e8.tar.bz2 gentoo-b889a401a8a2206855f053234df27195315871e8.zip |
dev-embedded/stm32flash: drop 0.6
Signed-off-by: Petr Vaněk <arkamar@gentoo.org>
Diffstat (limited to 'dev-embedded')
5 files changed, 0 insertions, 227 deletions
diff --git a/dev-embedded/stm32flash/Manifest b/dev-embedded/stm32flash/Manifest index e4e097bf8308..85abfecea490 100644 --- a/dev-embedded/stm32flash/Manifest +++ b/dev-embedded/stm32flash/Manifest @@ -1,2 +1 @@ -DIST stm32flash-0.6.tar.gz 376186 BLAKE2B 82e479b4fad2c3ff832aea9d0d62d556500fd8c0530e879690b9b83cdf05f078b0051e1e104e7cb64b9c360ef84415904639ee67ee147045ce8e15ca3f6c61e1 SHA512 2d92ecf4f82b8a702b596cbf3c4ff594f67083f7dcec82c064555f73b47834b41a918efa1846e47fc8740ae63fa818b16dfb5b38fa242c17f465666a651eee3a DIST stm32flash-0.7.tar.gz 380166 BLAKE2B 98522968072821e3cf110e62486a3b9ee90ac6c7e600f6633acbfac904024390157743f0895cae181fc9b20f4f14dc5b833c36e02de4adbfc644c797abd12d63 SHA512 328254dd043dc707cf8c3edf8ddd4a9441c85d9cb2ca1682bcb3f5301d526b04ed6fb335e72a94e3d26341f18bef45968bf321f0ffeb80eaa0c3add6701349ff diff --git a/dev-embedded/stm32flash/files/stm32flash-0.6-fix-i2c-erase-01fbb65.patch b/dev-embedded/stm32flash/files/stm32flash-0.6-fix-i2c-erase-01fbb65.patch deleted file mode 100644 index c4c7a2a7fedc..000000000000 --- a/dev-embedded/stm32flash/files/stm32flash-0.6-fix-i2c-erase-01fbb65.patch +++ /dev/null @@ -1,28 +0,0 @@ -From 01fbb65d4626e1c122e329075526bd6035cb0be6 Mon Sep 17 00:00:00 2001 -From: Tormod Volden <debian.tormod@gmail.com> -Date: Thu, 2 Sep 2021 16:25:57 +0200 -Subject: [PATCH 06/15] stm32: Fix typo from recent commit - -Oops, I got this wrong while amending commit b079cd09. - -Signed-off-by: Tormod Volden <debian.tormod@gmail.com> ---- - stm32.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/stm32.c b/stm32.c -index 6e2e402..0edaf01 100644 ---- a/stm32.c -+++ b/stm32.c -@@ -851,7 +851,7 @@ static stm32_err_t stm32_pages_erase(const stm32_t *stm, uint32_t spage, uint32_ - buf[i++] = pages - 1; - cs ^= (pages-1); - /* For I2C send a checksum after the number of pages (AN4221) */ -- if (port->flags && PORT_NPAG_CSUM) { -+ if (port->flags & PORT_NPAG_CSUM) { - buf[i++] = cs; - p_err = port->write(port, buf, i); - if (p_err != PORT_ERR_OK) { --- -2.33.0.309.g3052b89438-goog - diff --git a/dev-embedded/stm32flash/files/stm32flash-0.6-fix-i2c-erase-17a24f8.patch b/dev-embedded/stm32flash/files/stm32flash-0.6-fix-i2c-erase-17a24f8.patch deleted file mode 100644 index e0b519c48413..000000000000 --- a/dev-embedded/stm32flash/files/stm32flash-0.6-fix-i2c-erase-17a24f8.patch +++ /dev/null @@ -1,65 +0,0 @@ -From 17a24f873122b96481adefaadc128bd1abba594f Mon Sep 17 00:00:00 2001 -From: Tormod Volden <debian.tormod@gmail.com> -Date: Sat, 21 Aug 2021 13:06:34 +0200 -Subject: [PATCH 02/15] stm32: Consistent and unique erase error messages - -Signed-off-by: Tormod Volden <debian.tormod@gmail.com> ---- - stm32.c | 11 ++++++----- - 1 file changed, 6 insertions(+), 5 deletions(-) - -diff --git a/stm32.c b/stm32.c -index 82fa26a..e071905 100644 ---- a/stm32.c -+++ b/stm32.c -@@ -797,7 +797,7 @@ static stm32_err_t stm32_mass_erase(const stm32_t *stm) - return STM32_ERR_OK; - } - -- /* extended erase */ -+ /* extended erase (0x44 or 0x45) */ - buf[0] = 0xFF; /* 0xFFFF the magic number for mass erase */ - buf[1] = 0xFF; - buf[2] = 0x00; /* checksum */ -@@ -870,11 +870,12 @@ static stm32_err_t stm32_pages_erase(const stm32_t *stm, uint32_t spage, uint32_ - p_err = port->write(port, buf, i); - free(buf); - if (p_err != PORT_ERR_OK) { -- fprintf(stderr, "Erase failed.\n"); -+ fprintf(stderr, "Erase failed sending list of pages.\n"); - return STM32_ERR_UNKNOWN; - } - s_err = stm32_get_ack_timeout(stm, pages * STM32_PAGEERASE_TIMEOUT); - if (s_err != STM32_ERR_OK) { -+ fprintf(stderr, "Erase failed.\n"); - if (port->flags & PORT_STRETCH_W) - stm32_warn_stretching("erase"); - return STM32_ERR_UNKNOWN; -@@ -882,7 +883,7 @@ static stm32_err_t stm32_pages_erase(const stm32_t *stm, uint32_t spage, uint32_ - return STM32_ERR_OK; - } - -- /* extended erase */ -+ /* extended erase (0x44 or 0x45) */ - buf = malloc(2 + 2 * pages + 1); - if (!buf) - return STM32_ERR_UNKNOWN; -@@ -925,13 +926,13 @@ static stm32_err_t stm32_pages_erase(const stm32_t *stm, uint32_t spage, uint32_ - p_err = port->write(port, buf, i); - free(buf); - if (p_err != PORT_ERR_OK) { -- fprintf(stderr, "Page-by-page erase error.\n"); -+ fprintf(stderr, "Extended erase failed sending list of pages.\n"); - return STM32_ERR_UNKNOWN; - } - - s_err = stm32_get_ack_timeout(stm, pages * STM32_PAGEERASE_TIMEOUT); - if (s_err != STM32_ERR_OK) { -- fprintf(stderr, "Page-by-page erase failed. Check the maximum pages your device supports.\n"); -+ fprintf(stderr, "Extended erase failed. Check the maximum pages your device supports.\n"); - if ((port->flags & PORT_STRETCH_W) - && stm->cmd->er != STM32_CMD_EE_NS) - stm32_warn_stretching("erase"); --- -2.33.0.309.g3052b89438-goog - diff --git a/dev-embedded/stm32flash/files/stm32flash-0.6-fix-i2c-erase-b079cd0.patch b/dev-embedded/stm32flash/files/stm32flash-0.6-fix-i2c-erase-b079cd0.patch deleted file mode 100644 index dcd7299570c5..000000000000 --- a/dev-embedded/stm32flash/files/stm32flash-0.6-fix-i2c-erase-b079cd0.patch +++ /dev/null @@ -1,103 +0,0 @@ -From b079cd09bc942b4a489cad29524418441a44fc82 Mon Sep 17 00:00:00 2001 -From: Yann Sionneau <ysionneau@kalray.eu> -Date: Wed, 28 Apr 2021 14:16:01 +0200 -Subject: [PATCH 01/15] Follow bootloader protocol for page-by-page erase over - I2C - -For I2C the protocol is slighly different than for USART, -requiring a checksum after the number of pages. - -https://sourceforge.net/p/stm32flash/tickets/98/ - -Signed-off-by: Yann Sionneau <ysionneau@kalray.eu> -[Tormod: Add port flag, no wait, amend messages] -Signed-off-by: Tormod Volden <debian.tormod@gmail.com> ---- - i2c.c | 2 +- - port.h | 1 + - stm32.c | 37 +++++++++++++++++++++++++++++++++++++ - 3 files changed, 39 insertions(+), 1 deletion(-) - -diff --git a/i2c.c b/i2c.c -index bb99545..8425b41 100644 ---- a/i2c.c -+++ b/i2c.c -@@ -204,7 +204,7 @@ static port_err_t i2c_flush(struct port_interface __unused *port) - - struct port_interface port_i2c = { - .name = "i2c", -- .flags = PORT_STRETCH_W, -+ .flags = PORT_STRETCH_W | PORT_NPAG_CSUM, - .open = i2c_open, - .close = i2c_close, - .flush = i2c_flush, -diff --git a/port.h b/port.h -index 4e728d7..1a28dc6 100644 ---- a/port.h -+++ b/port.h -@@ -34,6 +34,7 @@ typedef enum { - #define PORT_CMD_INIT (1 << 2) /* use INIT cmd to autodetect speed */ - #define PORT_RETRY (1 << 3) /* allowed read() retry after timeout */ - #define PORT_STRETCH_W (1 << 4) /* warning for no-stretching commands */ -+#define PORT_NPAG_CSUM (1 << 5) /* checksum after number of pages to erase */ - - /* all options and flags used to open and configure an interface */ - struct port_options { -diff --git a/stm32.c b/stm32.c -index 966048b..82fa26a 100644 ---- a/stm32.c -+++ b/stm32.c -@@ -843,6 +843,25 @@ static stm32_err_t stm32_pages_erase(const stm32_t *stm, uint32_t spage, uint32_ - - buf[i++] = pages - 1; - cs ^= (pages-1); -+ /* For I2C send a checksum after the number of pages (AN4221) */ -+ if (port->flags && PORT_NPAG_CSUM) { -+ buf[i++] = cs; -+ p_err = port->write(port, buf, i); -+ if (p_err != PORT_ERR_OK) { -+ fprintf(stderr, "Erase failed sending number of pages."); -+ free(buf); -+ return STM32_ERR_UNKNOWN; -+ } -+ s_err = stm32_get_ack(stm); -+ if (s_err != STM32_ERR_OK) { -+ fprintf(stderr, "Erase failed, no ack after number of pages."); -+ free(buf); -+ return STM32_ERR_UNKNOWN; -+ } -+ cs = 0; -+ i = 0; -+ } -+ - for (pg_num = spage; pg_num < (pages + spage); pg_num++) { - buf[i++] = pg_num; - cs ^= pg_num; -@@ -876,6 +895,24 @@ static stm32_err_t stm32_pages_erase(const stm32_t *stm, uint32_t spage, uint32_ - buf[i++] = pg_byte; - cs ^= pg_byte; - -+ if (port->flags & PORT_NPAG_CSUM) { -+ buf[i++] = cs; -+ p_err = port->write(port, buf, i); -+ if (p_err != PORT_ERR_OK) { -+ fprintf(stderr, "Extended erase failed sending number of pages."); -+ free(buf); -+ return STM32_ERR_UNKNOWN; -+ } -+ s_err = stm32_get_ack(stm); -+ if (s_err != STM32_ERR_OK) { -+ fprintf(stderr, "Extended erase failed, no ack after number of pages."); -+ free(buf); -+ return STM32_ERR_UNKNOWN; -+ } -+ cs = 0; -+ i = 0; -+ } -+ - for (pg_num = spage; pg_num < spage + pages; pg_num++) { - pg_byte = pg_num >> 8; - cs ^= pg_byte; --- -2.33.0.309.g3052b89438-goog - diff --git a/dev-embedded/stm32flash/stm32flash-0.6.ebuild b/dev-embedded/stm32flash/stm32flash-0.6.ebuild deleted file mode 100644 index 34348ceabecc..000000000000 --- a/dev-embedded/stm32flash/stm32flash-0.6.ebuild +++ /dev/null @@ -1,30 +0,0 @@ -# Copyright 1999-2024 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -inherit toolchain-funcs - -DESCRIPTION="Open source flash program for STM32 using the ST serial bootloader" -HOMEPAGE="https://sourceforge.net/projects/stm32flash/" -SRC_URI="https://downloads.sourceforge.net/project/${PN}/${P}.tar.gz" - -LICENSE="GPL-2+" -SLOT="0" -KEYWORDS="~amd64 ~x86" - -PATCHES=( - "${FILESDIR}/stm32flash-0.6-fix-i2c-erase-b079cd0.patch" - "${FILESDIR}/stm32flash-0.6-fix-i2c-erase-17a24f8.patch" - "${FILESDIR}/stm32flash-0.6-fix-i2c-erase-01fbb65.patch" -) - -src_prepare() { - default - tc-export CC -} - -src_install() { - dobin ${PN} - doman ${PN}.1 -} |