Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1560983

Re: [PATCH v4 4/4] sparc64: Add support for ADI (Application Data Integrity)

From Khalid Aziz <khalid.aziz@oracle.com>
Newsgroups linux.kernel
Subject Re: [PATCH v4 4/4] sparc64: Add support for ADI (Application Data Integrity)
Date 2017-01-17 21:20 +0100
Message-ID <t0Ioy-38E-35@gated-at.bofh.it> (permalink)
References <sYtN0-Fd-25@gated-at.bofh.it> <t0tIS-2as-13@gated-at.bofh.it> <t0HLQ-2F3-15@gated-at.bofh.it> <t0I5b-2Md-15@gated-at.bofh.it>
Organization Oracle Corp

Show all headers | View raw


On 01/17/2017 12:42 PM, David Miller wrote:
> From: Khalid Aziz <khalid.aziz@oracle.com>
> Date: Tue, 17 Jan 2017 12:32:46 -0700
>
>> On 01/16/2017 09:39 PM, David Miller wrote:
>>> From: Khalid Aziz <khalid.aziz@oracle.com>
>>> Date: Wed, 11 Jan 2017 09:12:54 -0700
>>>
>>>> +		__asm__ __volatile__(
>>>> +			".word 0xa1438000\n\t"	/* rd  %mcdper, %l0 */
>>>
>>> Just use "rd %%asr14, %0" this way you don't have to play all of these
>>> fixed register games which kill the code generated by gcc.  If you
>>> forcefully clobber a windowed register like %l0 it means the function
>>> being emitted can never be a leaf function, tail calls are no longer
>>> allowed, etc.
>>
>> Hi David,
>>
>> "rd %%asr14, %0" should work but does not due to bugs in assembler -
>> <https://sourceware.org/ml/binutils/2016-03/msg00302.html>, and
>> <https://sourceware.org/ml/binutils/2016-03/msg00303.html>. These bugs
>> were fixed in binutils 2.27 but older assemblers will cause kernel
>> build to fail. Using byte coded equivalent is the safest option.
>
> Fair enough.
>
> Then please at least use %g1 or another usable global register to
> avoid at least some of the problems I mentioned.
>

Sure, I will do that. Thanks for the review and feedback.

--
Khalid

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Re: [PATCH v4 4/4] sparc64: Add support for ADI (Application Data  Integrity) David Miller <davem@davemloft.net> - 2017-01-17 05:40 +0100
  Re: [PATCH v4 4/4] sparc64: Add support for ADI (Application Data  Integrity) Khalid Aziz <khalid.aziz@oracle.com> - 2017-01-17 20:40 +0100
    Re: [PATCH v4 4/4] sparc64: Add support for ADI (Application Data  Integrity) David Miller <davem@davemloft.net> - 2017-01-17 21:00 +0100
      Re: [PATCH v4 4/4] sparc64: Add support for ADI (Application Data  Integrity) Khalid Aziz <khalid.aziz@oracle.com> - 2017-01-17 21:20 +0100
  Re: [PATCH v4 4/4] sparc64: Add support for ADI (Application Data  Integrity) Khalid Aziz <khalid.aziz@oracle.com> - 2017-01-18 01:20 +0100

csiph-web