Re: [kvm-unit-tests v3 PATCH 1/2] s390x: cleanup and add SCLP defines

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 17.12.18 14:38, David Hildenbrand wrote:
> Reading the Linux kernel SCLP code, one might wonder what certain magic
> values mean and why we don't have to set them in our SCLP code. So
> let's define them for us. We might want to make use of them in the
> future.
> 
> Add two new defines for values used in the linux kernel
> - SCLP_FC_SINGLE_INCREMENT_ASSIGN (used to speed up memory hotplug)
> - SCLP_FC_DUMP_INDICATOR (used to get more reasonable dumps)
> 
> Also rename SCLP_VARIABLE_LENGTH_RESPONSE to
> SCLP_CM2_VARIABLE_LENGTH_RESPONSE, so it is clear where this is actually
> used. Move the defines to separate sections.

LGTM
Reviewed-by: Janosch Frank <frankja@xxxxxxxxxxxxx>

> 
> Signed-off-by: David Hildenbrand <david@xxxxxxxxxx>
> ---
>  lib/s390x/sclp.h | 13 +++++++++----
>  1 file changed, 9 insertions(+), 4 deletions(-)
> 
> diff --git a/lib/s390x/sclp.h b/lib/s390x/sclp.h
> index 21d482b..629e9e2 100644
> --- a/lib/s390x/sclp.h
> +++ b/lib/s390x/sclp.h
> @@ -68,14 +68,19 @@
>  #define SCLP_RC_EVENT_BUFFER_SYNTAX_ERROR       0x73f0
>  #define SCLP_RC_INVALID_MASK_LENGTH             0x74f0
>  
> -/* Service Call Control Block (SCCB) and its elements */
> +/* SCLP control mask bits */
> +#define SCLP_CM2_VARIABLE_LENGTH_RESPONSE       0x80
>  
> -#define SCCB_SIZE 4096
> +/* SCLP function codes */
> +#define SCLP_FC_NORMAL_WRITE                    0
> +#define SCLP_FC_SINGLE_INCREMENT_ASSIGN         0x40
> +#define SCLP_FC_DUMP_INDICATOR                  0x80
>  
> -#define SCLP_VARIABLE_LENGTH_RESPONSE           0x80
> +/* SCLP event buffer flags */
>  #define SCLP_EVENT_BUFFER_ACCEPTED              0x80
>  
> -#define SCLP_FC_NORMAL_WRITE                    0
> +/* Service Call Control Block (SCCB) and its elements */
> +#define SCCB_SIZE 4096
>  
>  typedef struct SCCBHeader {
>      uint16_t length;
> 


Attachment: signature.asc
Description: OpenPGP digital signature


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux