Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1592623
| From | Borislav Petkov <bp@suse.de> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: Question Regarding ERMS memcpy |
| Date | 2017-03-04 23:50 +0100 |
| Message-ID | <thqEV-7AQ-5@gated-at.bofh.it> (permalink) |
| References | <thpfP-6Lj-13@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Sat, Mar 04, 2017 at 01:08:15PM -0700, Logan Gunthorpe wrote:
> So my question is: how do I find out what version of memcpy my actual
> machine is using and fix it if it is wrong?
You can boot with "debug-alternative" and look for those strings where
it says "feat:"
[ 0.261386] apply_alternatives: feat: 3*32+18, old: (ffffffff8101e3c4, len: 3), repl: (ffffffff81de4e7a, len: 3), pad: 3
^^^^^^^
[ 0.264003] ffffffff8101e3c4: old_insn: 0f 1f 00
[ 0.265235] ffffffff81de4e7a: rpl_insn: 0f ae e8
[ 0.266469] ffffffff8101e3c4: final_insn: 0f ae e8
if it says 9*32+9 there, then it really does patch in the ERMS variant.
If it says 3*32+16 and it patches a NOP, i.e., something like this:
[ 2.022665] apply_alternatives: feat: 3*32+16, old: (ffffffff812dbfe0, len: 5), repl: (ffffffff81de5336, len: 0), pad: 3
[ 2.024003] ffffffff812dbfe0: old_insn: eb 0e 90 90 90
[ 2.025332] ffffffff812dbfe0: final_insn: 0f 1f 44 00 00
^^^^ NOP
then, you're using the rep; movsq variant.
Also, do
make <path-to-file>.s
of the file where it does memcpy_fromio() and attach it here. I'd like to see
what the compiler generates.
HTH.
--
Regards/Gruss,
Boris.
SUSE Linux GmbH, GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg)
--
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Question Regarding ERMS memcpy Logan Gunthorpe <logang@deltatee.com> - 2017-03-04 22:20 +0100
Re: Question Regarding ERMS memcpy Borislav Petkov <bp@suse.de> - 2017-03-04 23:50 +0100
Re: Question Regarding ERMS memcpy hpa@zytor.com - 2017-03-05 01:00 +0100
Re: Question Regarding ERMS memcpy Borislav Petkov <bp@suse.de> - 2017-03-05 01:20 +0100
Re: Question Regarding ERMS memcpy hpa@zytor.com - 2017-03-05 01:30 +0100
Re: Question Regarding ERMS memcpy Borislav Petkov <bp@suse.de> - 2017-03-05 01:40 +0100
Re: Question Regarding ERMS memcpy hpa@zytor.com - 2017-03-05 02:00 +0100
Re: Question Regarding ERMS memcpy Borislav Petkov <bp@suse.de> - 2017-03-05 11:00 +0100
Re: Question Regarding ERMS memcpy Borislav Petkov <bp@suse.de> - 2017-03-05 12:20 +0100
Re: Question Regarding ERMS memcpy Borislav Petkov <bp@suse.de> - 2017-03-05 14:10 +0100
Re: Question Regarding ERMS memcpy Linus Torvalds <torvalds@linux-foundation.org> - 2017-03-05 20:30 +0100
Re: Question Regarding ERMS memcpy Borislav Petkov <bp@suse.de> - 2017-03-05 21:20 +0100
Re: Question Regarding ERMS memcpy Linus Torvalds <torvalds@linux-foundation.org> - 2017-03-05 21:20 +0100
Re: Question Regarding ERMS memcpy Logan Gunthorpe <logang@deltatee.com> - 2017-03-06 08:10 +0100
Re: Question Regarding ERMS memcpy "H. Peter Anvin" <hpa@zytor.com> - 2017-03-06 08:40 +0100
Re: Question Regarding ERMS memcpy Logan Gunthorpe <logang@deltatee.com> - 2017-03-06 18:50 +0100
Re: Question Regarding ERMS memcpy hpa@zytor.com - 2017-03-06 20:10 +0100
Re: Question Regarding ERMS memcpy Borislav Petkov <bp@suse.de> - 2017-03-06 14:40 +0100
Re: Question Regarding ERMS memcpy hpa@zytor.com - 2017-03-06 14:50 +0100
Re: Question Regarding ERMS memcpy Borislav Petkov <bp@suse.de> - 2017-03-06 15:10 +0100
Re: Question Regarding ERMS memcpy Logan Gunthorpe <logang@deltatee.com> - 2017-03-05 06:00 +0100
Re: Question Regarding ERMS memcpy Borislav Petkov <bp@suse.de> - 2017-03-05 11:00 +0100
csiph-web