mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-23 19:14:30 +08:00
Short summary of fixes pull:
* kmb: DMA fix; Add macros for driver date/version * vmwgfx: Fix I/O memory access on 64-bit systems -----BEGIN PGP SIGNATURE----- iQEzBAABCAAdFiEEchf7rIzpz2NEoWjlaA3BHVMLeiMFAmEK12oACgkQaA3BHVML eiOUgggAmPgu9spDXi4pnKmLMZ3Y85X2I5WsYiTLV15JszOJys/oP6z87pLpzMPZ 9Z31xpP0UBsJy1sfEGLEdL1cvf3tubzOMzCkqThNywz69uLRPulhqvriSkDoLeij VwOcEaRkUToB0PHYZRXcblujvyxXD4sjRRR5TtnL9jNCcI09+uybMkKiEWkAhQ6n wAba7hm0Vd6GEqdoG51W10yx0zqUhffjse+9u5jMxYgUgR/OdadsdL95DE3yLZoE HgUxa8trM0LKmkzirabGUjp54g3XD8l0Z76y+v/C+OhPBStdBgixgn2tGAx4Y4lb 6RfyjxPwoqC+q7iwqZ4oonMDV3EdpQ== =U/xo -----END PGP SIGNATURE----- Merge tag 'drm-misc-fixes-2021-08-04' of git://anongit.freedesktop.org/drm/drm-misc into drm-fixes Short summary of fixes pull: * kmb: DMA fix; Add macros for driver date/version * vmwgfx: Fix I/O memory access on 64-bit systems Signed-off-by: Dave Airlie <airlied@redhat.com> From: Thomas Zimmermann <tzimmermann@suse.de> Link: https://patchwork.freedesktop.org/patch/msgid/YQrXzTmPpiuWsqSA@linux-uq9g.fritz.box
This commit is contained in:
commit
e8a1ca91c8
@ -203,6 +203,7 @@ static irqreturn_t handle_lcd_irq(struct drm_device *dev)
|
||||
unsigned long status, val, val1;
|
||||
int plane_id, dma0_state, dma1_state;
|
||||
struct kmb_drm_private *kmb = to_kmb(dev);
|
||||
u32 ctrl = 0;
|
||||
|
||||
status = kmb_read_lcd(kmb, LCD_INT_STATUS);
|
||||
|
||||
@ -227,6 +228,19 @@ static irqreturn_t handle_lcd_irq(struct drm_device *dev)
|
||||
kmb_clr_bitmask_lcd(kmb, LCD_CONTROL,
|
||||
kmb->plane_status[plane_id].ctrl);
|
||||
|
||||
ctrl = kmb_read_lcd(kmb, LCD_CONTROL);
|
||||
if (!(ctrl & (LCD_CTRL_VL1_ENABLE |
|
||||
LCD_CTRL_VL2_ENABLE |
|
||||
LCD_CTRL_GL1_ENABLE |
|
||||
LCD_CTRL_GL2_ENABLE))) {
|
||||
/* If no LCD layers are using DMA,
|
||||
* then disable DMA pipelined AXI read
|
||||
* transactions.
|
||||
*/
|
||||
kmb_clr_bitmask_lcd(kmb, LCD_CONTROL,
|
||||
LCD_CTRL_PIPELINE_DMA);
|
||||
}
|
||||
|
||||
kmb->plane_status[plane_id].disable = false;
|
||||
}
|
||||
}
|
||||
@ -411,10 +425,10 @@ static const struct drm_driver kmb_driver = {
|
||||
.fops = &fops,
|
||||
DRM_GEM_CMA_DRIVER_OPS_VMAP,
|
||||
.name = "kmb-drm",
|
||||
.desc = "KEEMBAY DISPLAY DRIVER ",
|
||||
.date = "20201008",
|
||||
.major = 1,
|
||||
.minor = 0,
|
||||
.desc = "KEEMBAY DISPLAY DRIVER",
|
||||
.date = DRIVER_DATE,
|
||||
.major = DRIVER_MAJOR,
|
||||
.minor = DRIVER_MINOR,
|
||||
};
|
||||
|
||||
static int kmb_remove(struct platform_device *pdev)
|
||||
|
@ -15,6 +15,11 @@
|
||||
#define KMB_MAX_HEIGHT 1080 /*Max height in pixels */
|
||||
#define KMB_MIN_WIDTH 1920 /*Max width in pixels */
|
||||
#define KMB_MIN_HEIGHT 1080 /*Max height in pixels */
|
||||
|
||||
#define DRIVER_DATE "20210223"
|
||||
#define DRIVER_MAJOR 1
|
||||
#define DRIVER_MINOR 1
|
||||
|
||||
#define KMB_LCD_DEFAULT_CLK 200000000
|
||||
#define KMB_SYS_CLK_MHZ 500
|
||||
|
||||
|
@ -427,8 +427,14 @@ static void kmb_plane_atomic_update(struct drm_plane *plane,
|
||||
|
||||
kmb_set_bitmask_lcd(kmb, LCD_CONTROL, ctrl);
|
||||
|
||||
/* FIXME no doc on how to set output format,these values are
|
||||
* taken from the Myriadx tests
|
||||
/* Enable pipeline AXI read transactions for the DMA
|
||||
* after setting graphics layers. This must be done
|
||||
* in a separate write cycle.
|
||||
*/
|
||||
kmb_set_bitmask_lcd(kmb, LCD_CONTROL, LCD_CTRL_PIPELINE_DMA);
|
||||
|
||||
/* FIXME no doc on how to set output format, these values are taken
|
||||
* from the Myriadx tests
|
||||
*/
|
||||
out_format |= LCD_OUTF_FORMAT_RGB888;
|
||||
|
||||
@ -526,6 +532,11 @@ struct kmb_plane *kmb_plane_init(struct drm_device *drm)
|
||||
plane->id = i;
|
||||
}
|
||||
|
||||
/* Disable pipeline AXI read transactions for the DMA
|
||||
* prior to setting graphics layers
|
||||
*/
|
||||
kmb_clr_bitmask_lcd(kmb, LCD_CONTROL, LCD_CTRL_PIPELINE_DMA);
|
||||
|
||||
return primary;
|
||||
cleanup:
|
||||
drmm_kfree(drm, plane);
|
||||
|
@ -492,7 +492,7 @@ struct vmw_private {
|
||||
resource_size_t vram_start;
|
||||
resource_size_t vram_size;
|
||||
resource_size_t prim_bb_mem;
|
||||
void __iomem *rmmio;
|
||||
u32 __iomem *rmmio;
|
||||
u32 *fifo_mem;
|
||||
resource_size_t fifo_mem_size;
|
||||
uint32_t fb_max_width;
|
||||
|
Loading…
Reference in New Issue
Block a user