From patchwork Tue Jan 7 16:30:08 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Tokarev X-Patchwork-Id: 13929321 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 35E8AE77197 for ; Tue, 7 Jan 2025 16:30:41 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tVCTK-0002sI-Ih; Tue, 07 Jan 2025 11:30:26 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tVCTH-0002mp-T0 for qemu-devel@nongnu.org; Tue, 07 Jan 2025 11:30:24 -0500 Received: from isrv.corpit.ru ([86.62.121.231]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tVCTE-0003Rf-VL for qemu-devel@nongnu.org; Tue, 07 Jan 2025 11:30:23 -0500 Received: from tsrv.corpit.ru (tsrv.tls.msk.ru [192.168.177.2]) by isrv.corpit.ru (Postfix) with ESMTP id 62617D29AF; Tue, 7 Jan 2025 19:29:13 +0300 (MSK) Received: from [192.168.177.130] (mjt.wg.tls.msk.ru [192.168.177.130]) by tsrv.corpit.ru (Postfix) with ESMTP id C80BF19641A; Tue, 7 Jan 2025 19:30:08 +0300 (MSK) Message-ID: <9b64bbe0-473d-4f6b-a673-356e74517fb4@tls.msk.ru> Date: Tue, 7 Jan 2025 19:30:08 +0300 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird To: BALATON Zoltan Content-Language: en-US, ru-RU Cc: qemu-devel From: Michael Tokarev Subject: A few patches for u-boot-sam460ex Autocrypt: addr=mjt@tls.msk.ru; keydata= xsFNBGYpLkcBEACsajkUXU2lngbm6RyZuCljo19q/XjZTMikctzMoJnBGVSmFV66kylUghxs HDQQF2YZJbnhSVt/mP6+V7gG6MKR5gYXYxLmypgu2lJdqelrtGf1XtMrobG6kuKFiD8OqV6l 2M5iyOZT3ydIFOUX0WB/B9Lz9WcQ6zYO9Ohm92tiWWORCqhAnwZy4ua/nMZW3RgO7bM6GZKt /SFIorK9rVqzv40D6KNnSyeWfqf4WN3EvEOozMfWrXbEqA7kvd6ShjJoe1FzCEQ71Fj9dQHL DZG+44QXvN650DqEtQ4RW9ozFk3Du9u8lbrXC5cqaCIO4dx4E3zxIddqf6xFfu4Oa5cotCM6 /4dgxDoF9udvmC36qYta+zuDsnAXrYSrut5RBb0moez/AR8HD/cs/dS360CLMrl67dpmA+XD 7KKF+6g0RH46CD4cbj9c2egfoBOc+N5XYyr+6ejzeZNf40yjMZ9SFLrcWp4yQ7cpLsSz08lk a0RBKTpNWJdblviPQaLW5gair3tyJR+J1ER1UWRmKErm+Uq0VgLDBDQoFd9eqfJjCwuWZECp z2JUO+zBuGoKDzrDIZH2ErdcPx3oSlVC2VYOk6H4cH1CWr9Ri8i91ClivRAyVTbs67ha295B y4XnxIVaZU+jJzNgLvrXrkI1fTg4FJSQfN4W5BLCxT4sq8BDtwARAQABzSBNaWNoYWVsIFRv a2FyZXYgPG1qdEB0bHMubXNrLnJ1PsLBlAQTAQoAPhYhBJ2L4U4/Kp3XkZko8WGtPZjs3yyO BQJmKS5HAhsDBQkSzAMABQsJCAcCBhUKCQgLAgQWAgMBAh4BAheAAAoJEGGtPZjs3yyOZSAP /ibilK1gbHqEI2zR2J59Dc0tjtbByVmQ8IMh0SYU3j1jeUoku2UCgdnGKpwvLXtwZINgdl6Q cEaDBRX6drHLJFAi/sdgwVgdnDxaW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ZBUfBlYnArssIZSOpdJ9wWMK+fl5gn54cs+yziUYU3Tgk0fJ t0DzQsgfd2JkxOEzJACjJWti2Gh3szmdgdoPEJH1Og7KeqbOu2mVCJm+2PrNlzCybOZuHOV5 +vSarkb69qg9nU+4ZGX1m+EFLDqVUt1g0SjY6QmM5yjGBA46G3dwTEV0/u5Wh7idNT0mRg8R eP/62iTL55AM6QARAQABwsF8BBgBCgAmFiEEnYvhTj8qndeRmSjxYa09mOzfLI4FAmYpLkcC GwwFCRLMAwAACgkQYa09mOzfLI53ag/+ITb3WW9iqvbjDueV1ZHwUXYvebUEyQV7BFofaJbJ Sr7ek46iYdV4Jdosvq1FW+mzuzrhT+QzadEfYmLKrQV4EK7oYTyQ5hcch55eX00o+hyBHqM2 RR/B5HGLYsuyQNv7a08dAUmmi9eAktQ29IfJi+2Y+S1okAEkWFxCUs4EE8YinCrVergB/MG5 S7lN3XxITIaW00faKbqGtNqij3vNxua7UenN8NHNXTkrCgA+65clqYI3MGwpqkPnXIpTLGl+ wBI5S540sIjhgrmWB0trjtUNxe9QcTGHoHtLeGX9QV5KgzNKoUNZsyqh++CPXHyvcN3OFJXm VUNRs/O3/b1capLdrVu+LPd6Zi7KAyWUqByPkK18+kwNUZvGsAt8WuVQF5telJ6TutfO8xqT FUzuTAHE+IaRU8DEnBpqv0LJ4wqqQ2MeEtodT1icXQ/5EDtM7OTH231lJCR5JxXOnWPuG6el YPkzzso6HT7rlapB5nulYmplJZSZ4RmE1ATZKf+wUPocDu6N10LtBNbwHWTT5NLtxNJAJAvl ojis6H1kRWZE/n5buyPY2NYeyWfjjrerOYt3er55n4C1I88RSCTGeejVmXWuo65QD2epvzE6 3GgKngeVm7shlp7+d3D3+fAAHTvulQQqV3jOodz+B4yzuZ7WljkNrmrWrH8aI4uA98c= Received-SPF: pass client-ip=86.62.121.231; envelope-from=mjt@tls.msk.ru; helo=isrv.corpit.ru X-Spam_score_int: -68 X-Spam_score: -6.9 X-Spam_bar: ------ X-Spam_report: (-6.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_HI=-5, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Hi! For some time, qemu package in debian carries several patches for roms/u-boot-sam460ex, fixing a number of issues. It'd be nice to have them in the official repository. Thanks, /mjt From: Michael Tokarev Date: Sat, 03 Aug 2024 11:18:58 +0300 Subject: u-boot-sam460ex: build fixes Fixes or works around numerous build issues and one real bug. Most are due to new defaults in gcc (in debian), like -Werror=implicit-function-declarations (there are a lot of missing decls) -Werror=incompatible-pointer-types (function types mismatches) -Werror=int-conversion (free int <=> pointer conversion) Bug-Debian: https://bugs.debian.org/1075428 Signed-off-by: Michael Tokarev diff --git a/roms/u-boot-sam460ex/board/ACube/Sam460ex/Sam460ex.c b/roms/u-boot-sam460ex/board/ACube/Sam460ex/Sam460ex.c index 4d5b953c02..5ecf16dbe2 100644 --- a/roms/u-boot-sam460ex/board/ACube/Sam460ex/Sam460ex.c +++ b/roms/u-boot-sam460ex/board/ACube/Sam460ex/Sam460ex.c @@ -843,7 +843,7 @@ int last_stage_init (void) // cleanup last 8 bytes of the RTC registers bank ----- char arr[8] = { 0 }; - i2c_write(0x68, 0x08, 1, &arr, 8); + i2c_write(0x68, 0x08, 1, arr, 8); // USB Init ------------------------------------------- diff --git a/roms/u-boot-sam460ex/common/usb.c b/roms/u-boot-sam460ex/common/usb.c index 203c9f7795..d645d36c8e 100644 --- a/roms/u-boot-sam460ex/common/usb.c +++ b/roms/u-boot-sam460ex/common/usb.c @@ -957,7 +957,7 @@ void usb_scan_devices(void) printf("%d USB Device(s) found\n", dev_index); #ifdef CONFIG_SAM460EX - static attempts = 0; + static int attempts = 0; if (dev_index < 3) { u16 fpga_val = in_be16((void *)CONFIG_SYS_FPGA_BASE + 0x2E); diff --git a/roms/u-boot-sam460ex/config.mk b/roms/u-boot-sam460ex/config.mk index bcda77611a..9928f5f4c6 100644 --- a/roms/u-boot-sam460ex/config.mk +++ b/roms/u-boot-sam460ex/config.mk @@ -191,6 +191,11 @@ endif CFLAGS += $(call cc-option,-fno-stack-protector) +# this u-boot is an old bad code +CFLAGS += $(call cc-option,-Wno-error=implicit-function-declaration) +CFLAGS += $(call cc-option,-Wno-error=incompatible-pointer-types) +CFLAGS += $(call cc-option,-Wno-error=int-conversion) + # $(CPPFLAGS) sets -g, which causes gcc to pass a suitable -g # option to the assembler. AFLAGS_DEBUG :=