[PATCH] video: hyperv: hyperv_fb: Use physical memory for fb on HyperV Gen 1 VMs.

Dexuan Cui decui at microsoft.com
Sat Nov 2 06:17:21 UTC 2019


> From: linux-hyperv-owner at vger.kernel.org
> <linux-hyperv-owner at vger.kernel.org> On Behalf Of Wei Hu
> Sent: Tuesday, October 22, 2019 4:11 AM
> ... 
> +	/* Allocate from CMA */
> +	// request_pages = (request_size >> PAGE_SHIFT) + 1;

"//" seems rare in Linux kernel code.
IMO "/* */" is more common.

> +			pr_info("Unable to allocate enough contiguous physical memory
> on Gen 1 VM. Use MMIO instead.\n");

The line exceeds 80 chars.
 
> @@ -1060,6 +1168,7 @@ static int hvfb_probe(struct hv_device *hdev,
>  	par = info->par;
>  	par->info = info;
>  	par->fb_ready = false;
> +	par->need_docopy = false;

Maybe it's better if we set the default value to true? This way we can save
the "	par->need_docopy = true;" in hvfb_getmem().

Thanks,
-- Dexuan


More information about the dri-devel mailing list