Received: by 2002:a25:d7c1:0:0:0:0:0 with SMTP id o184csp4026273ybg; Fri, 25 Oct 2019 12:16:03 -0700 (PDT) X-Google-Smtp-Source: APXvYqzIANOptTGRKrvKuQiRRfSKm5wy8noCXn9/TUa9+ZGcJSMph6adRSmKufZaxq8PdMVr02GG X-Received: by 2002:aa7:d658:: with SMTP id v24mr5743193edr.301.1572030963582; Fri, 25 Oct 2019 12:16:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1572030963; cv=none; d=google.com; s=arc-20160816; b=sVNyEE0P23RPLQv2qXQzqz+gFDflGW9sblQDY0VQdR3IRhDz7s5FhY/BX1+RcnKqPN fIJ9ShBSuyUt8QqMJjaSK5gDjSOx4eiraTMZjW/1D/xUSgyHYk7DWEKUtZuHGQpqQRC3 Zu94z7yrbtu90MpQj8JgmpQdmBbucECx1rTwdyjibm1CgD7RRhWXbn+WXtZOEniv0o2G Y9X9PB40nZ4TJF5gy/OM5vCnbwQFrlfxNDuyR1nBl0UdJp9D0w/nFjtCgCjXzEtee3uD JdqcYkxvh5nor3uiFyPzTNZv+NubR4vomFXg3AZ1kd+7LkViaQuIJb2a3p+TKG9VmdGf Ipcw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=LUBTpk9ooV35xQmJoHGn2mN1fpHGsBmiJOBvpI0fOq4=; b=KcIlim65TcL3fWGLHrRFNCixLwCD1ynyBxgJMgaZXKMmz7PueeQsZEwzOPtzpgc8V2 KS3ElcnGqYizl7S2xQPFXQ2WCXz8wpafIov9yxjhiO9GkJPlic6izRJjsCqewYr/HRbs kTbE7O0LEgQ6cqbdZfYKUVvwbu2LulRt7hRuMoFWwgI/aqA75GohnIa0cUAxHI8p7t4F brgRTk/FH8yHR9gbEk2FnkOyrKrfpTDM7sUNP6G2anQbxM8x/72522lFnwwvYe9zgl/g TCRVvmAkc9gTBVIb/RSwW1GEPNI3lUDvxrR0osPHY9MrkpjjnGlxelFAuCtROgU1xOi7 iFcg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@sifive.com header.s=google header.b=IEZZ4Tea; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l45si2041343edc.185.2019.10.25.12.15.40; Fri, 25 Oct 2019 12:16:03 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@sifive.com header.s=google header.b=IEZZ4Tea; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732047AbfJXW6v (ORCPT + 99 others); Thu, 24 Oct 2019 18:58:51 -0400 Received: from mail-io1-f66.google.com ([209.85.166.66]:43285 "EHLO mail-io1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730384AbfJXW6v (ORCPT ); Thu, 24 Oct 2019 18:58:51 -0400 Received: by mail-io1-f66.google.com with SMTP id c11so189318iom.10 for ; Thu, 24 Oct 2019 15:58:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sifive.com; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=LUBTpk9ooV35xQmJoHGn2mN1fpHGsBmiJOBvpI0fOq4=; b=IEZZ4TeaPYu9KusTwoj7WfdPn1cK9KTxR4CsgVIUWzNM7sVDrk3QIl2JqN9AP1q0fD mQXxqZpLv+F4Ydq+wQp+MJN/9hawT5YJAt+K9tIz6QieiXo0WvRn8I3QJPxmkUA/T0hn cpV5d5m4J3wPcN2XdvKbdGsqTagFTIPB8b/3uzjMERWxapHtaBLtmCNwGpnmZdsLLejh FhVD6WbH5LS1wKsH4UWrLuZQ27dBPSyLar0UMkbAufifbBJb9MamMy0Jjn3rcFBLSNp8 ZhWEIPwBzFvS5cxxxuHtZWn7eq8Y7pAtrgiUUXBzQ66D4OswlcQgnNug4JdMNlAxil2E aWSg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=LUBTpk9ooV35xQmJoHGn2mN1fpHGsBmiJOBvpI0fOq4=; b=nNdi/dAYX2NXt1vMjw7YhyAd+oH+Dt5aqiwrwjVrxqBvSO6tH4YmYyscKTH2n/3KOx vY13dXfq9X3MVZzxuWJb5FKDNVnALrRH721qbUgbGD6Epm615NHEjRdXiHs+mhJpgpfX hjCjWx3EauUS2R1LtqulufXXhYVZxEdV4kY7UbTYn2Rz9rjHEzn5OHLp/zHRW0EBZCAb tq4vwSOS/lphnIn1NuWBL63n1tyWQwpW1OrRC0vLcD13A2JAii79dMldOTUptNPPdMoH D1a5JZueOGNGP4AbBzJSsHy9kVgmF7pEdIVtX88mR1BLABpffWw8wqZjtKIhj+5/RR4D UQ8A== X-Gm-Message-State: APjAAAUAD3HYCotWNFPS0ENzgiTKXiTuhQW4FPw8iifyNjxBxCzVkP5C KrPcuzOgm0Noi1hjxz8mnwHqcw== X-Received: by 2002:a5d:8d0e:: with SMTP id p14mr637597ioj.4.1571957928395; Thu, 24 Oct 2019 15:58:48 -0700 (PDT) Received: from viisi.Home ([64.62.168.194]) by smtp.gmail.com with ESMTPSA id b18sm58112ilo.70.2019.10.24.15.58.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 24 Oct 2019 15:58:47 -0700 (PDT) From: Paul Walmsley To: linux-riscv@lists.infradead.org Cc: linux-kernel@vger.kernel.org, hch@lst.dev, greentime.hu@sifive.com, luc.vanoostenryck@gmail.com Subject: [PATCH v4 0/8] riscv: resolve most warnings from sparse Date: Thu, 24 Oct 2019 15:58:32 -0700 Message-Id: <20191024225838.27743-1-paul.walmsley@sifive.com> X-Mailer: git-send-email 2.24.0.rc0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Resolve most warnings from the 'sparse' static analysis tool for the arch/riscv codebase. This makes life easier for us as maintainers, and makes it easier for developers to use static analysis tools on their own changes. This fourth version drops some patches that were in the previous versions, and restructures some of what was left. Much of this was based on feedback from Christoph Hellwig , Luc Van Oostenryck , and Greentime Hu . Applies on the current riscv fixes branch, which itself is based on v5.4-rc5. Tested on RV32 QEMU, RV64 QEMU, and the SiFive HiFive Unleashed board. - Paul Paul Walmsley (6): riscv: add prototypes for assembly language functions from head.S riscv: init: merge split string literals in preprocessor directive riscv: mark some code and data as file-static riscv: add missing header file includes riscv: fp: add missing __user pointer annotations riscv: for C functions called only from assembly, mark with __visible Kernel object size difference: text data bss dec hex filename 6662533 2136168 312608 9111309 8b070d vmlinux.rv64.orig 6662537 2136160 312608 9111305 8b0709 vmlinux.rv64.patched 6443041 1792976 255184 8491201 8190c1 vmlinux.rv32.orig 6443021 1792968 255184 8491173 8190a5 vmlinux.rv32.patched arch/riscv/include/asm/irq.h | 3 +++ arch/riscv/include/asm/switch_to.h | 1 + arch/riscv/kernel/cpufeature.c | 1 + arch/riscv/kernel/head.h | 21 +++++++++++++++++++++ arch/riscv/kernel/irq.c | 2 +- arch/riscv/kernel/module-sections.c | 1 + arch/riscv/kernel/process.c | 2 ++ arch/riscv/kernel/ptrace.c | 4 ++-- arch/riscv/kernel/reset.c | 1 + arch/riscv/kernel/setup.c | 2 ++ arch/riscv/kernel/signal.c | 8 ++++---- arch/riscv/kernel/smp.c | 2 ++ arch/riscv/kernel/smpboot.c | 5 ++++- arch/riscv/kernel/syscall_table.c | 1 + arch/riscv/kernel/time.c | 1 + arch/riscv/kernel/traps.c | 5 +++-- arch/riscv/kernel/vdso.c | 3 ++- arch/riscv/mm/context.c | 1 + arch/riscv/mm/fault.c | 2 ++ arch/riscv/mm/init.c | 5 +++-- arch/riscv/mm/sifive_l2_cache.c | 2 +- 21 files changed, 59 insertions(+), 14 deletions(-) create mode 100644 arch/riscv/kernel/head.h -- 2.24.0.rc0