[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 6/6] ieee1275: implement vec5 for cas negotiation
From: |
Daniel Axtens |
Subject: |
Re: [PATCH 6/6] ieee1275: implement vec5 for cas negotiation |
Date: |
Wed, 17 Aug 2022 01:11:55 +1000 |
Diego Domingos <diegodo@linux.vnet.ibm.com> writes:
> As a legacy support, if the vector 5 is not implemented, Power Hypervisor will
> consider the max CPUs as 64 instead 256 currently supported during
> client-architecture-support negotiation.
>
> This patch implements the vector 5 and set the MAX CPUs to 256 while setting
> the
> others values to 0 (default).
Ergh, CAS. I'm sorry I didn't check the defaults more carefully when I
was at IBM!
Anyway, this looks sane to me. I'm not in a position to test it any
more, but it certainly follows the pattern I'd expect. And it is only
likely to affect IBM machines anyway, so I think it's safe to add.
> +struct option_vector5 {
> + grub_uint8_t byte1;
> + grub_uint8_t byte2;
> + grub_uint8_t byte3;
> + grub_uint8_t cmo;
> + grub_uint8_t associativity;
> + grub_uint8_t bin_opts;
> + grub_uint8_t micro_checkpoint;
> + grub_uint8_t reserved0;
> + grub_uint32_t max_cpus;
> +} __attribute__((packed));
> +
I think the indent here should be 2 spaces?
> +
> struct pvr_entry {
> grub_uint32_t mask;
> grub_uint32_t entry;
> @@ -512,6 +525,8 @@ struct cas_vector {
> grub_uint16_t vec3;
> grub_uint8_t vec4_size;
> grub_uint16_t vec4;
> + grub_uint8_t vec5_size;
> + struct option_vector5 vec5;
> } __attribute__((packed));
>
> /*
> @@ -534,7 +549,7 @@ grub_ieee1275_ibm_cas (void)
> } args;
> struct cas_vector vector = {
> .pvr_list = { { 0x00000000, 0xffffffff } }, /* any processor */
> - .num_vecs = 4 - 1,
> + .num_vecs = 5 - 1,
> .vec1_size = 0,
> .vec1 = 0x80, /* ignore */
> .vec2_size = 1 + sizeof(struct option_vector2) - 2,
> @@ -545,6 +560,10 @@ grub_ieee1275_ibm_cas (void)
> .vec3 = 0x00e0, /* ask for FP + VMX + DFP but don't halt if unsatisfied
> */
> .vec4_size = 2 - 1,
> .vec4 = 0x0001, /* set required minimum capacity % to the lowest value */
> + .vec5_size = 1 + sizeof(struct option_vector5) - 2,
> + .vec5 = {
> + 0, 0, 0, 0, 0, 0, 0, 0, 256
This maybe should be indented 6 spaces instead of 1 tab? But I wouldn't
do a whole new revision just for this.
Acked-by: Daniel Axtens <dja@axtens.net>
Kind regards,
Daniel
- [PATCH 0/6] Dynamic allocation of memory regions and IBM vTPM v2, Diego Domingos, 2022/08/11
- [PATCH 0/6] Dynamic allocation of memory regions and IBM vTPM v2, Diego Domingos, 2022/08/11
- [PATCH 1/6] ieee1275: request memory with ibm, client-architecture-support, Diego Domingos, 2022/08/11
- [PATCH 2/6] ieee1275: drop len -= 1 quirk in heap_init, Diego Domingos, 2022/08/11
- [PATCH 5/6] ibmvtpm: Add support for trusted boot using a vTPM 2.0, Diego Domingos, 2022/08/11
- [PATCH 3/6] ieee1275: support runtime memory claiming, Diego Domingos, 2022/08/11
- [PATCH 6/6] ieee1275: implement vec5 for cas negotiation, Diego Domingos, 2022/08/11
- Re: [PATCH 6/6] ieee1275: implement vec5 for cas negotiation,
Daniel Axtens <=
- [PATCH 4/6] Add memtool module with memory allocation stress-test, Diego Domingos, 2022/08/11