From patchwork Thu Feb 15 17:17:25 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Serge Semin X-Patchwork-Id: 20449 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:b825:b0:106:860b:bbdd with SMTP id da37csp548558dyb; Thu, 15 Feb 2024 09:18:12 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCWCyEZ9ka9iD8a5MpYO1GVhr50y+0+e01N6vzcnDBNapmS+5o+rS/t7MIminVqY8hWu9txYOBITvO/iM5G6QPTNnyM/bA== X-Google-Smtp-Source: AGHT+IEtQ7Y3nUrCdyKhyru13izNQFGksq4QG3DuZal7aBnfsOcDyil5YthL3y8CCx9a7IegF+OK X-Received: by 2002:a17:902:ccc6:b0:1db:8c27:c23f with SMTP id z6-20020a170902ccc600b001db8c27c23fmr2642253ple.19.1708017492550; Thu, 15 Feb 2024 09:18:12 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708017492; cv=pass; d=google.com; s=arc-20160816; b=C+TssfmYcVvds7wLFg5i/h6BIdwEVEIVGub6q8oDgl7wmwbUf1oEjpTcIIjr1OYWMv d4PhTcDbLCYF10WLInvSsqM/A8PH+p+JMvLv25xoK0rYOq2yTpHQcRIiumtNFuAa6FvT 0Z1Z6ZSUiLfSCi3ffs+WcsAb6q0US2On0LSEuxyAhbz9AK2Onc4NsQYyYIX1Mq2lYgbG 3n7UrG4IqSjaylJYIq6CucAk3CTmkj7Fy8UV0N+vM1tBo+poCdbdliyBGNrsowXPm40A U89aBFTraAoAt96q6y9p6w8T7nL4DFBEJ4aGPeYypbTVJG9ygUYJlviNOfIphVRAhPiI B5og== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=H34U5Vbhdh0VVX7V6tBXcBBMhZVVWdzHO2tS/G9vxsA=; fh=MfauX3VcFdlbp/HNr6npBBcHESISA+LoFFhAk9bcczI=; b=nj6J8iB8y+J25X/vJnTW97xud5aGDfFXXuxFPH+Gq/ZYovsAdgEVs2wsGymOotrSoM blF/h65vtqm3nbn/Xpz6AQv35/QXPt3dy+wq0DWDR1y0hUyQ6DVsJzQNOaG8/yvP+enk bemICWrFS8XERxRzZntPD5ia4qa+DNWrXASujnJoF8U1ff7K89azsmudp+h6wsHXl23o BwdvA1N+CnrlVUFQGm2Fx4gTB2mDkYVgL7amKPcI2VSI0QkH3MySKGvHZjPG0D/CxtGA ffwoVezrIvyGQ5GfdvBdSyphARFZQjA8rg8GxyhBPkq0BI3E1o7NamW+5nVlxx8hbrey OZtg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=aWANoxYD; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-67385-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-67385-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id bi11-20020a170902bf0b00b001d98fc60058si1420668plb.190.2024.02.15.09.18.12 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 15 Feb 2024 09:18:12 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-67385-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=aWANoxYD; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-67385-ouuuleilei=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-67385-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 2B5B728B8A7 for ; Thu, 15 Feb 2024 17:18:12 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id ED6071369B1; Thu, 15 Feb 2024 17:17:57 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="aWANoxYD" Received: from mail-lf1-f51.google.com (mail-lf1-f51.google.com [209.85.167.51]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 03B1513399E; Thu, 15 Feb 2024 17:17:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.51 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708017475; cv=none; b=uFJwldy4fYPQMvMiZAgdV+SNLd3SylGcKzWB+SPJ5/fNCUgnMRPs/ZvFJmxplX2/QRh7IH+RHVNwSgLR1ncy5ew3jf02vVx+lbMcfTNDOuNM6W9wKoDNCmteBNg+fSdBXrLjxDE4ZF5GYEegkL1KQlZhAzUwvUBwiI8NUNk6HnA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708017475; c=relaxed/simple; bh=tfaViPks8NnM283/X+IeiZHNZJ7mRUXnXQTI9qhFnNU=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type; b=t4Izb1BCIRI+vzw8a/VV+TJ31eVG2QRD+L076X8lthc6iwPd604bT4cOHEpwaKecvNoBOsXCZqIvcoX9kXD0JS/sA0ZJXxSdaXAsXY41CTfGPRVu4VztJPfiM7WP9L87NIgzZ9FP+8/Hof1S0D4hN2tdE8Tz0rviIXpQnaT2f0M= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=aWANoxYD; arc=none smtp.client-ip=209.85.167.51 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-lf1-f51.google.com with SMTP id 2adb3069b0e04-511a4a1c497so1245138e87.3; Thu, 15 Feb 2024 09:17:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1708017471; x=1708622271; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=H34U5Vbhdh0VVX7V6tBXcBBMhZVVWdzHO2tS/G9vxsA=; b=aWANoxYDdxSHqOZ4/dmVvI+NsM8jhc8P8oGIIawFFnH6+mIBZ2UIypvbdJr2vnedBJ OGsYDrOd44IUBoxLQa3jXEHpahtMx4sbBCmqHLR8hmf47QmLVRgwsTUHumEo9QqxeYKv fVu5zEo/u9jsRsubL5CtWdaljD1Y0IEnMBJS1AmuwG17YYP2Yr38NEqCjKuPwo0zGrje b5JfTkmP1oprbymcGtpYqyCT7c9wpYwGLyChDi6aale7rQ9Mv3lYPns9yc01PSxy4hg0 NM36Cth8NrYzSIpw1VGRAv+wGzeOa782aUm2wQY+J1jjHCsIoqfl9gg9zBD+3vsghCmN vyIg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708017471; x=1708622271; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=H34U5Vbhdh0VVX7V6tBXcBBMhZVVWdzHO2tS/G9vxsA=; b=A/HL3yUxy99jWPaSdhLYTn97tkmu+JLsHVQ6zdZ4lBONEuz6yCuLgUD0bTETFHEMYO mdPe7EjNB1zxSJhKxpozOSgaArlxAk3HHhmcHkIChfhzL0iyekEz5Ct0qvG0FbEcnWui m10cwuDUsC0/l9iUG/QtWzyx5GgBliRMrkfnguaTCjcYHntiIY3TEgfsx777dbFc9kCh J+w+YSMk1EeK5Oth6xVvcfabbYZ4/PmaiWl7JA6G7aOm8M6C4QRGoYcHiEhWPlTZeBBi 7+EuY/YpANmGqZyj8nJ0gdBkgVOJkPpjXeGkocwHT/xdIyEK30CcQ73rg+ErqjZ32XLZ 9OZw== X-Forwarded-Encrypted: i=1; AJvYcCVXRq/Zw/CSIWM0wnJJryoAPwSAFGOrE5tTmGay84bES+Zc1+dcQepqGwllM1LPZdtloAYIVoPsKDcuY741Kk1LGbujxhcE7ik71keEOnKI1SY7zGRWszfzuuM1bleh8IKN2BxjuziMhoGTtZUSGxW84ZQ/n74r9XpaM4g++DhpkMHh4qNtCQ== X-Gm-Message-State: AOJu0YyQ4NaRJZoZ8y8YHxOatLayRcnQywhlFMJZAU9roTpmzbB2tmCm u7tHmxos0kiS7yon1gseIFeBsz4W2dtfPNev5znw1T7WVlO6hrTC X-Received: by 2002:a05:6512:31d1:b0:512:8d6d:4804 with SMTP id j17-20020a05651231d100b005128d6d4804mr934022lfe.15.1708017470617; Thu, 15 Feb 2024 09:17:50 -0800 (PST) Received: from localhost ([178.176.56.174]) by smtp.gmail.com with ESMTPSA id m26-20020a05651202fa00b00511a289c0c9sm308209lfq.306.2024.02.15.09.17.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 15 Feb 2024 09:17:50 -0800 (PST) From: Serge Semin To: Thomas Bogendoerfer , Greg Kroah-Hartman , Jiri Slaby , Arnd Bergmann , Jiaxun Yang Cc: Serge Semin , Alexey Malahov , Stephen Rothwell , Andrew Morton , linux-mips@vger.kernel.org, linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 0/4] MIPS: Fix missing proto and passing arg warnings Date: Thu, 15 Feb 2024 20:17:25 +0300 Message-ID: <20240215171740.14550-1-fancer.lancer@gmail.com> X-Mailer: git-send-email 2.43.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1790986150547586677 X-GMAIL-MSGID: 1790986150547586677 After getting my local tree rebased onto the kernel 6.8-rc3 the MIPS32 kernel build procedure produced a couple of warnings which I suggest to fix in the framework of this series. A first warning is of the "no previous prototype for ``" type. In particular my arch-specific code has the mips_cm_l2sync_phys_base() method re-defined, but even though the function is global it' prototype isn't declared anywhere. Fix that by adding the method prototype declaration to the mips/include/asm/mips-cm.h header file. A similar solution was provided for the methods: __mips_cm_l2sync_phys_base() mips_cm_phys_base() __mips_cm_phys_base() too (Please see the patches 1/4 and 2/4 notes section for an alternative suggestion of the way to fix the warning). One more case of the denoted warning I spotted in the self-extracting kernel (so called zboot) with the debug printouts enabled. In particular there are several putc() method re-definitions available in: arch/mips/boot/compressed/uart-prom.c arch/mips/boot/compressed/uart-16550.c arch/mips/boot/compressed/uart-alchemy.c All of these files lacked the prototype declaration what caused having the "no previous prototype for ‘putc’" printed on my build with the next configs enabled: CONFIG_SYS_SUPPORTS_ZBOOT=y CONFIG_SYS_SUPPORTS_ZBOOT_UART_PROM=y CONFIG_ZBOOT_LOAD_ADDRESS=0x85100000 CONFIG_DEBUG_ZBOOT=y The second warning is of the "passing argument of ‘’ from incompatible pointer type" type which I discovered in the drivers/tty/mips_ejtag_fdc.c driver. The problem most likely happened due to the commit ce7cbd9a6c81 ("tty: mips_ejtag_fdc: use u8 for character pointers"). That's it for today.) Thanks for review in advance. Any tests are very welcome. Cc: Alexey Malahov Cc: Stephen Rothwell Cc: Andrew Morton Cc: linux-mips@vger.kernel.org Cc: linux-serial@vger.kernel.org Cc: linux-kernel@vger.kernel.org Serge Semin (4): mips: cm: Add __mips_cm_l2sync_phys_base prototype declaration mips: cm: Add CM GCR and L2-sync base address getters declarations mips: zboot: Fix "no previous prototype" build warning tty: mips_ejtag_fdc: Fix passing incompatible pointer type warning arch/mips/boot/compressed/uart-16550.c | 2 ++ arch/mips/boot/compressed/uart-alchemy.c | 2 ++ arch/mips/boot/compressed/uart-prom.c | 2 ++ arch/mips/include/asm/mips-cm.h | 16 ++++++++++++++++ arch/mips/kernel/mips-cm.c | 2 +- drivers/tty/mips_ejtag_fdc.c | 2 +- 6 files changed, 24 insertions(+), 2 deletions(-)