...

Text file src/internal/cpu/cpu_s390x.s

Documentation: internal/cpu

     1// Copyright 2018 The Go Authors. All rights reserved.
     2// Use of this source code is governed by a BSD-style
     3// license that can be found in the LICENSE file.
     4
     5#include "textflag.h"
     6
     7// func stfle() facilityList
     8TEXT ·stfle(SB), NOSPLIT|NOFRAME, $0-32
     9	MOVD $ret+0(FP), R1
    10	MOVD $3, R0          // last doubleword index to store
    11	XC   $32, (R1), (R1) // clear 4 doublewords (32 bytes)
    12	WORD $0xb2b01000     // store facility list extended (STFLE)
    13	RET
    14
    15// func kmQuery() queryResult
    16TEXT ·kmQuery(SB), NOSPLIT|NOFRAME, $0-16
    17	MOVD $0, R0         // set function code to 0 (KM-Query)
    18	MOVD $ret+0(FP), R1 // address of 16-byte return value
    19	KM   R2, R4         // cipher message (KM)
    20	RET
    21
    22// func kmcQuery() queryResult
    23TEXT ·kmcQuery(SB), NOSPLIT|NOFRAME, $0-16
    24	MOVD $0, R0         // set function code to 0 (KMC-Query)
    25	MOVD $ret+0(FP), R1 // address of 16-byte return value
    26	KMC  R2, R4         // cipher message with chaining (KMC)
    27	RET
    28
    29// func kmctrQuery() queryResult
    30TEXT ·kmctrQuery(SB), NOSPLIT|NOFRAME, $0-16
    31	MOVD $0, R0         // set function code to 0 (KMCTR-Query)
    32	MOVD $ret+0(FP), R1 // address of 16-byte return value
    33	KMCTR R2, R4, R4    // cipher message with counter (KMCTR)
    34	RET
    35
    36// func kmaQuery() queryResult
    37TEXT ·kmaQuery(SB), NOSPLIT|NOFRAME, $0-16
    38	MOVD $0, R0         // set function code to 0 (KMA-Query)
    39	MOVD $ret+0(FP), R1 // address of 16-byte return value
    40	KMA  R2, R6, R4     // cipher message with authentication (KMA)
    41	RET
    42
    43// func kimdQuery() queryResult
    44TEXT ·kimdQuery(SB), NOSPLIT|NOFRAME, $0-16
    45	MOVD $0, R0         // set function code to 0 (KIMD-Query)
    46	MOVD $ret+0(FP), R1 // address of 16-byte return value
    47	KIMD R2, R4         // compute intermediate message digest (KIMD)
    48	RET
    49
    50// func klmdQuery() queryResult
    51TEXT ·klmdQuery(SB), NOSPLIT|NOFRAME, $0-16
    52	MOVD $0, R0         // set function code to 0 (KLMD-Query)
    53	MOVD $ret+0(FP), R1 // address of 16-byte return value
    54	KLMD R2, R4         // compute last message digest (KLMD)
    55	RET
    56
    57// func kdsaQuery() queryResult
    58TEXT ·kdsaQuery(SB), NOSPLIT|NOFRAME, $0-16
    59	MOVD $0, R0         // set function code to 0 (KLMD-Query)
    60	MOVD $ret+0(FP), R1 // address of 16-byte return value
    61	KDSA R0, R4      // compute digital signature authentication
    62	RET
    63

View as plain text