Re: [PATCH v2 12/30] s390/pci: get SHM information from list pci

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

 



On Fri, 2022-01-14 at 15:31 -0500, Matthew Rosato wrote:
> KVM will need information on the special handle mask used to indicate
> emulated devices.  In order to obtain this, a new type of list pci call
> must be made to gather the information.  Extend clp_list_pci_req to
> also fetch the model-dependent-data field that holds this mask.
> 
> Signed-off-by: Matthew Rosato <mjrosato@xxxxxxxxxxxxx>
> ---
>  arch/s390/include/asm/pci.h     |  1 +
>  arch/s390/include/asm/pci_clp.h |  2 +-
>  arch/s390/pci/pci_clp.c         | 28 +++++++++++++++++++++++++---
>  3 files changed, 27 insertions(+), 4 deletions(-)
> 
---8<---
>  
> +int zpci_get_mdd(u32 *mdd)
> +{
> +	struct clp_req_rsp_list_pci *rrb;
> +	u64 resume_token = 0;
> +	int nentries, rc;
> +
> +	if (!mdd)
> +		return -EINVAL;
> +
> +	rrb = clp_alloc_block(GFP_KERNEL);
> +	if (!rrb)
> +		return -ENOMEM;
> +
> +	rc = clp_list_pci_req(rrb, &resume_token, &nentries, mdd);
> +
> +	clp_free_block(rrb);
> +	return rc;
> +}
> +EXPORT_SYMBOL_GPL(zpci_get_mdd);
> +
>  static int clp_base_slpc(struct clp_req *req, struct clp_req_rsp_slpc *lpcb)
>  {
>  	unsigned long limit = PAGE_SIZE - sizeof(lpcb->request);

Looks good.

Reviewed-by: Niklas Schnelle <schnelle@xxxxxxxxxxxxx>





[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Kernel Development]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Info]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Linux Media]     [Device Mapper]

  Powered by Linux