From patchwork Tue Aug 8 23:44:06 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Randy Dunlap X-Patchwork-Id: 133012 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:c44e:0:b0:3f2:4152:657d with SMTP id w14csp2501323vqr; Tue, 8 Aug 2023 18:33:56 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHKvXpB0hs7B5f8xqS4LFt2344l0ZRE9zlRcM9zAiTNXsT4AYSnDJvRgTMdqAvyDEVIZ3uC X-Received: by 2002:a17:906:224e:b0:99c:b65b:54ed with SMTP id 14-20020a170906224e00b0099cb65b54edmr944498ejr.60.1691544836147; Tue, 08 Aug 2023 18:33:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691544836; cv=none; d=google.com; s=arc-20160816; b=oAxRk2OdZKZ0pCCAea3/K5ryvhyZ+nd2UPk1BgK8LX+zjK8QNkE8NzRa3oWDKrJ+bE 5ewFuJwicLEV16H+ruT7nc1M79dnrN4Ua8JUHzFwSHUceSSNgzQagttVkGtHXIWdv2el I3eAHKWTjp4lbbGp0ZCKtSFQBWlAFs140RraTsZGrsrcjJ9mnzcskvspUS5QYnB5tyTl Ehoys3WyjW6Q+i+t+22XLc3bk5KUxpvzljAGfY90vS8lNNtVVIi0zjZX42JFHoLQ5v4K wSgHLv4t5+2orRSUuuAoI8+PUWwGp/rhrah7MhXn6ENcWVuryiP9aN/zZUOGZXexMW+s pTqA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=aG8Y30PwCSThWsDEUczlXw9O6NJ4yxnIzNTeQ/Re6VE=; fh=I58wyTuNWA10cbkPvOcQw9zHpRnhHafbkczHgqtOvsM=; b=07QC3b0wvk2YvsW5LF0UMaxzZmmK35jQbQxCUgr95tPuC/5eIcPaLaqkxPWzyAuSzS 9oX+2siE90wTdXIG0aJ1kpYNetI0gUN1FLbnb0SK/7xPcuZYgAAnWwyZt3SU0mF1f3TR F/tE+TRGSS8NvWPMi9lLafD8mBdJ74Mbb42phh2ZtvtLv3voiZLoN56h3BgetnEcEQMt LZcjWAZKgV5FAqLYbN02L7SVARuk8asTs/gTrEiL62SYLMWvYpYB4RPQ2pAHJ8ASt8na k4Z5rfnW/BTZTLIX6p7CP6WS2op9qv52sMQn5pyOwaiuUJd5ulIMeJxaKR+tMUsbjj98 pChw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=315zny3s; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id gh4-20020a170906e08400b0098e4aef078esi8475133ejb.778.2023.08.08.18.33.33; Tue, 08 Aug 2023 18:33:56 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=315zny3s; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230188AbjHHXoJ (ORCPT + 99 others); Tue, 8 Aug 2023 19:44:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56014 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229501AbjHHXoI (ORCPT ); Tue, 8 Aug 2023 19:44:08 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 490FAF0 for ; Tue, 8 Aug 2023 16:44:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:Message-ID:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type: Content-ID:Content-Description:In-Reply-To:References; bh=aG8Y30PwCSThWsDEUczlXw9O6NJ4yxnIzNTeQ/Re6VE=; b=315zny3skUm3SJxNptuWnL+oWk wAi1xQCXr5MIKI/k/OINHtkRs/NY2qeJW6XOQvlI2nVdVymy3ffRji2Ju2GkY2IDGjXef4DAKhGVJ Lrou2g9/ltK69tdjuFrzUzs8JE7V/kpvrf15GpDAxrKarjcWOaHmMSkCAvuR1e8hGevamvZ4f7Mxb gKW0iiEIaNagEIVTAOudiT8VDvIlvurRaNkvyFrB1PbISLpwgvAcXloAvvD17RzVocOvJRHl9TLZP 0zcd1o+sRCGIYOxMm4MQK/CD6RGd0oSQpdcz5Y4R3fv4/kxEFe/jJ/2hqnXC2mJwg/r+ZTECt90r7 MzCCWnSQ==; Received: from [2601:1c2:980:9ec0::2764] (helo=bombadil.infradead.org) by bombadil.infradead.org with esmtpsa (Exim 4.96 #2 (Red Hat Linux)) id 1qTWMx-003gfH-27; Tue, 08 Aug 2023 23:44:07 +0000 From: Randy Dunlap To: linux-kernel@vger.kernel.org Cc: Randy Dunlap , kernel test robot , Nick Desaulniers , Arnd Bergmann , Nathan Chancellor , "Russell King (Oracle)" , Russell King , linux-arm-kernel@lists.infradead.org, patches@armlinux.org.uk Subject: [PATCH] ARM: locomo: move kernel-doc to prevent warnings Date: Tue, 8 Aug 2023 16:44:06 -0700 Message-ID: <20230808234406.24414-1-rdunlap@infradead.org> X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1773713318303619798 X-GMAIL-MSGID: 1773713318303619798 Move the kernel-doc comments for locomo_probe() to immediately before that function instead of before __locomo_probe() to prevent kernel-doc warnings. Adjust the documented function parameters and make the return values compatible with ReST by adding bullets to them. Add more possible return values to the list. Prevents these warnings: arch/arm/common/locomo.c:368: warning: Function parameter or member 'me' not described in '__locomo_probe' arch/arm/common/locomo.c:368: warning: Function parameter or member 'mem' not described in '__locomo_probe' arch/arm/common/locomo.c:368: warning: Function parameter or member 'irq' not described in '__locomo_probe' arch/arm/common/locomo.c:368: warning: expecting prototype for locomo_probe(). Prototype was for __locomo_probe() instead Fixes: 5eb6e280432d ("ARM: 9289/1: Allow pre-ARMv5 builds with ld.lld 16.0.0 and newer") Signed-off-by: Randy Dunlap Reported-by: kernel test robot Link: lore.kernel.org/r/202308050851.zAvHe6y7-lkp@intel.com Cc: Nick Desaulniers Cc: Arnd Bergmann Cc: Nathan Chancellor Cc: "Russell King (Oracle)" Cc: Russell King Cc: linux-arm-kernel@lists.infradead.org Cc: patches@armlinux.org.uk --- KernelVersion: 6.5-rc5 arch/arm/common/locomo.c | 28 +++++++++++++++------------- 1 file changed, 15 insertions(+), 13 deletions(-) diff -- a/arch/arm/common/locomo.c b/arch/arm/common/locomo.c --- a/arch/arm/common/locomo.c +++ b/arch/arm/common/locomo.c @@ -350,19 +350,6 @@ static int locomo_resume(struct platform } #endif - -/** - * locomo_probe - probe for a single LoCoMo chip. - * @phys_addr: physical address of device. - * - * Probe for a LoCoMo chip. This must be called - * before any other locomo-specific code. - * - * Returns: - * %-ENODEV device not found. - * %-EBUSY physical address already marked in-use. - * %0 successful. - */ static int __locomo_probe(struct device *me, struct resource *mem, int irq) { @@ -479,6 +466,21 @@ static void __locomo_remove(struct locom kfree(lchip); } +/** + * locomo_probe - probe for a single LoCoMo chip. + * @dev: platform device + * + * Probe for a LoCoMo chip. This must be called + * before any other locomo-specific code. + * + * Returns: + * * %-EINVAL - device's IORESOURCE_MEM not found + * * %-ENXIO - could not allocate an IRQ for the device + * * %-ENODEV - device not found. + * * %-EBUSY - physical address already marked in-use. + * * %-ENOMEM - could not allocate or iomap memory. + * * %0 - successful. + */ static int locomo_probe(struct platform_device *dev) { struct resource *mem;