From: kbuild test robot <fengguang.wu@intel.com>
To: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com>
Cc: kbuild-all@01.org, linux-kernel@vger.kernel.org,
Ingo Molnar <mingo@kernel.org>,
Matt Fleming <matt@codeblueprint.co.uk>
Subject: arch/x86/platform/efi/efi_64.c:212:15: sparse: memcpy with byte count of 0
Date: Wed, 10 May 2017 02:07:57 +0800 [thread overview]
Message-ID: <201705100220.4Hbrp2En%fengguang.wu@intel.com> (raw)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 2868b2513aa732a99ea4a0a6bf10dc93c1f3dac2
commit: e981316f560482c001dede7f5b29259bde0b8afb x86/efi: Add 5-level paging support
date: 6 weeks ago
reproduce:
# apt-get install sparse
git checkout e981316f560482c001dede7f5b29259bde0b8afb
make ARCH=x86_64 allmodconfig
make C=1 CF=-D__CHECK_ENDIAN__
sparse warnings: (new ones prefixed by >>)
>> arch/x86/platform/efi/efi_64.c:212:15: sparse: memcpy with byte count of 0
vim +212 arch/x86/platform/efi/efi_64.c
196 num_entries = pgd_index(EFI_VA_END) - pgd_index(PAGE_OFFSET);
197 memcpy(pgd_efi, pgd_k, sizeof(pgd_t) * num_entries);
198
199 /*
200 * As with PGDs, we share all P4D entries apart from the one entry
201 * that covers the EFI runtime mapping space.
202 */
203 BUILD_BUG_ON(p4d_index(EFI_VA_END) != p4d_index(MODULES_END));
204 BUILD_BUG_ON((EFI_VA_START & P4D_MASK) != (EFI_VA_END & P4D_MASK));
205
206 pgd_efi = efi_pgd + pgd_index(EFI_VA_END);
207 pgd_k = pgd_offset_k(EFI_VA_END);
208 p4d_efi = p4d_offset(pgd_efi, 0);
209 p4d_k = p4d_offset(pgd_k, 0);
210
211 num_entries = p4d_index(EFI_VA_END);
> 212 memcpy(p4d_efi, p4d_k, sizeof(p4d_t) * num_entries);
213
214 /*
215 * We share all the PUD entries apart from those that map the
216 * EFI regions. Copy around them.
217 */
218 BUILD_BUG_ON((EFI_VA_START & ~PUD_MASK) != 0);
219 BUILD_BUG_ON((EFI_VA_END & ~PUD_MASK) != 0);
220
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
reply other threads:[~2017-05-09 18:08 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201705100220.4Hbrp2En%fengguang.wu@intel.com \
--to=fengguang.wu@intel.com \
--cc=kbuild-all@01.org \
--cc=kirill.shutemov@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=matt@codeblueprint.co.uk \
--cc=mingo@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®