From patchwork Wed Oct 16 07:06:32 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michal Simek X-Patchwork-Id: 283868 X-Patchwork-Delegate: monstr@monstr.eu Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 264692C0351 for ; Wed, 16 Oct 2013 18:07:20 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id BA4054A0BD; Wed, 16 Oct 2013 09:07:18 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id sx5gqMH13OVA; Wed, 16 Oct 2013 09:07:18 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id A0C7B4A0BF; Wed, 16 Oct 2013 09:07:03 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 78FDB4A09B for ; Wed, 16 Oct 2013 09:06:54 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 8kOOl7fUAbtn for ; Wed, 16 Oct 2013 09:06:49 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 BL_NJABL=SKIP(-1.5) (only DNSBL check requested) Received: from mail-ea0-f171.google.com (mail-ea0-f171.google.com [209.85.215.171]) by theia.denx.de (Postfix) with ESMTPS id 36EDD4A09D for ; Wed, 16 Oct 2013 09:06:44 +0200 (CEST) Received: by mail-ea0-f171.google.com with SMTP id n15so137795ead.2 for ; Wed, 16 Oct 2013 00:06:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:subject:date:message-id :in-reply-to:references:in-reply-to:references:content-type; bh=5kOIL3w/RPjnoLDCVAnHtTeLvLB+GX6KOi+GbuKQS1Y=; b=fBk8/KvtEAJ2Ktlxz14XIrX+3nO356l6cOmtz0xdLX/ZtCb7Z7hUAeupSMR85iLDHS shquAW+fDmMUxnpvmhccJBG3kIEHw0pjraudwxCi1Qstmg+/pJ8HywcCG9+bInm7ehlv XnsQN9/E+/RocBkiYxckMJMuxMYOk9rPNH+wFk46EWwKGWUjFWtnf7e+HCAzzmKyFxJD EvrN8eI6lE2VOnt8zYgoVg1yoAvp4QmjZMP5fdShCvowbpn5b3cycB+r0eN2DiTxB1lZ bTWs7c/WO6aUt1hZ8dTPQV8kWzyC2ATkz3fwWedHh/eV2nZf8owJ7X/6ajBLLEPCyzte KGbQ== X-Gm-Message-State: ALoCoQnONqmZ/Uac670XYNlHPrjlG54g9Uyeaz/mIocUP81sU+rdLxkauMZt96r4KwZoPwunJb1L X-Received: by 10.15.32.7 with SMTP id z7mr32423eeu.78.1381907204367; Wed, 16 Oct 2013 00:06:44 -0700 (PDT) Received: from localhost (nat-63.starnet.cz. [178.255.168.63]) by mx.google.com with ESMTPSA id d8sm175988875eeh.8.1969.12.31.16.00.00 (version=TLSv1.1 cipher=RC4-SHA bits=128/128); Wed, 16 Oct 2013 00:06:43 -0700 (PDT) From: Michal Simek To: Tom Rini , u-boot@lists.denx.de Date: Wed, 16 Oct 2013 09:06:32 +0200 Message-Id: X-Mailer: git-send-email 1.8.2.3 In-Reply-To: References: In-Reply-To: References: Subject: [U-Boot] [PATCH 2/2] microblaze: Fix watchdog initialization X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de The patch: "blackfin: Move blackfin watchdog driver out of the blackfin arch folder." (sha1: e9a389a18477c1c57a0b30e9ea8f4d38c6e26e63) changed hw_watchdog_init() prototype which didn't match with Microblaze one. This patch fixes the driver and Microblaze initialization. Signed-off-by: Michal Simek --- Compilation error: /mnt/disk/u-boot/include/asm/processor.h:19:12: error: conflicting types for 'hw_watchdog_init' /mnt/disk/u-boot/include/watchdog.h:96:7: note: previous declaration of 'hw_watchdog_init' was here --- arch/microblaze/include/asm/processor.h | 1 - arch/microblaze/lib/board.c | 6 +++--- drivers/watchdog/xilinx_tb_wdt.c | 6 ++---- 3 files changed, 5 insertions(+), 8 deletions(-) -- 1.8.2.3 diff --git a/arch/microblaze/include/asm/processor.h b/arch/microblaze/include/asm/processor.h index a2a5811..5afc8f9 100644 --- a/arch/microblaze/include/asm/processor.h +++ b/arch/microblaze/include/asm/processor.h @@ -16,7 +16,6 @@ extern char __text_start[]; void board_init(void); /* Watchdog functions */ -extern int hw_watchdog_init(void); extern void hw_watchdog_disable(void); #endif /* __ASM_MICROBLAZE_PROCESSOR_H */ diff --git a/arch/microblaze/lib/board.c b/arch/microblaze/lib/board.c index f7182f2..896e73a 100644 --- a/arch/microblaze/lib/board.c +++ b/arch/microblaze/lib/board.c @@ -46,9 +46,6 @@ init_fnc_t *init_sequence[] = { serial_init, console_init_f, interrupts_init, -#ifdef CONFIG_XILINX_TB_WATCHDOG - hw_watchdog_init, -#endif timer_init, NULL, }; @@ -97,6 +94,9 @@ void board_init_f(ulong not_used) serial_initialize(); +#ifdef CONFIG_XILINX_TB_WATCHDOG + hw_watchdog_init(); +#endif for (init_fnc_ptr = init_sequence; *init_fnc_ptr; ++init_fnc_ptr) { WATCHDOG_RESET(); if ((*init_fnc_ptr) () != 0) diff --git a/drivers/watchdog/xilinx_tb_wdt.c b/drivers/watchdog/xilinx_tb_wdt.c index 4e46e4c..6336c94 100644 --- a/drivers/watchdog/xilinx_tb_wdt.c +++ b/drivers/watchdog/xilinx_tb_wdt.c @@ -54,7 +54,7 @@ static void hw_watchdog_isr(void *arg) hw_watchdog_reset(); } -int hw_watchdog_init(void) +void hw_watchdog_init(void) { int ret; @@ -65,7 +65,5 @@ int hw_watchdog_init(void) ret = install_interrupt_handler(CONFIG_WATCHDOG_IRQ, hw_watchdog_isr, NULL); if (ret) - return 1; - - return 0; + puts("Watchdog IRQ registration failed."); }