Displaying 13 results from an estimated 13 matches for "pci_platform_rom".
2020 Mar 19
2
[PATCH v3] PCI: Use ioremap(), not phys_to_virt() for platform ROM
...odule+0x21/0x220
do_init_module+0x50/0x220
load_module+0x1f26/0x2200
sys_init_module+0x12d/0x160
do_fast_syscall_32+0x82/0x250
entry_SYSENTER_32+0xa5/0xf8
Fix the issue by updating all drivers which can access a platform
provided ROM. Instead of calling the helper function pci_platform_rom()
which uses phys_to_virt(), call ioremap() directly on the pdev->rom.
radeon_read_platform_bios() previously directly accessed an __iomem
pointer. Avoid this by calling memcpy_fromio() instead of kmemdup().
pci_platform_rom() now has no remaining callers, so remove it.
Signed-off-by: Mikel R...
2020 Mar 30
1
[PATCH v3] PCI: Use ioremap(), not phys_to_virt() for platform ROM
...26/0x2200
> > sys_init_module+0x12d/0x160
> > do_fast_syscall_32+0x82/0x250
> > entry_SYSENTER_32+0xa5/0xf8
> >
> > Fix the issue by updating all drivers which can access a platform
> > provided ROM. Instead of calling the helper function
> > pci_platform_rom() which uses phys_to_virt(), call ioremap() directly on
> the pdev->rom.
> >
> > radeon_read_platform_bios() previously directly accessed an __iomem
> > pointer. Avoid this by calling memcpy_fromio() instead of kmemdup().
> >
> > pci_platform_rom() now has no rem...
2020 Mar 28
0
[PATCH v3] PCI: Use ioremap(), not phys_to_virt() for platform ROM
...e+0x50/0x220
> load_module+0x1f26/0x2200
> sys_init_module+0x12d/0x160
> do_fast_syscall_32+0x82/0x250
> entry_SYSENTER_32+0xa5/0xf8
>
> Fix the issue by updating all drivers which can access a platform
> provided ROM. Instead of calling the helper function pci_platform_rom()
> which uses phys_to_virt(), call ioremap() directly on the pdev->rom.
>
> radeon_read_platform_bios() previously directly accessed an __iomem
> pointer. Avoid this by calling memcpy_fromio() instead of kmemdup().
>
> pci_platform_rom() now has no remaining callers, so remo...
2020 Mar 17
2
[PATCH RESEND v2 2/2] PCI: Use ioremap(), not phys_to_virt() for platform ROM
On Fri, Mar 13, 2020 at 06:22:58PM -0400, Mikel Rychliski wrote:
> /**
> + * pci_platform_rom - ioremap() the ROM image provided by the platform
> * @pdev: pointer to pci device struct
> * @size: pointer to receive size of pci window over ROM
> + *
> + * Return: kernel virtual pointer to image of ROM
> + *
> + * The caller is responsible for removing the mapping with i...
2020 Apr 11
0
[PATCH AUTOSEL 5.5 121/121] PCI: Use ioremap(), not phys_to_virt() for platform ROM
...nit+0x533/0xa50 [radeon]
radeon_driver_load_kms+0x80/0x220 [radeon]
drm_dev_register+0xa7/0x180 [drm]
radeon_pci_probe+0x10f/0x1a0 [radeon]
pci_device_probe+0xd4/0x140
Fix the issue by updating all drivers which can access a platform provided
ROM. Instead of calling the helper function pci_platform_rom() which uses
phys_to_virt(), call ioremap() directly on the pdev->rom.
radeon_read_platform_bios() previously directly accessed an __iomem
pointer. Avoid this by calling memcpy_fromio() instead of kmemdup().
pci_platform_rom() now has no remaining callers, so remove it.
Link: https://lore.ker...
2020 Apr 11
0
[PATCH AUTOSEL 5.6 149/149] PCI: Use ioremap(), not phys_to_virt() for platform ROM
...nit+0x533/0xa50 [radeon]
radeon_driver_load_kms+0x80/0x220 [radeon]
drm_dev_register+0xa7/0x180 [drm]
radeon_pci_probe+0x10f/0x1a0 [radeon]
pci_device_probe+0xd4/0x140
Fix the issue by updating all drivers which can access a platform provided
ROM. Instead of calling the helper function pci_platform_rom() which uses
phys_to_virt(), call ioremap() directly on the pdev->rom.
radeon_read_platform_bios() previously directly accessed an __iomem
pointer. Avoid this by calling memcpy_fromio() instead of kmemdup().
pci_platform_rom() now has no remaining callers, so remove it.
Link: https://lore.ker...
2020 Apr 11
0
[PATCH AUTOSEL 5.4 108/108] PCI: Use ioremap(), not phys_to_virt() for platform ROM
...nit+0x533/0xa50 [radeon]
radeon_driver_load_kms+0x80/0x220 [radeon]
drm_dev_register+0xa7/0x180 [drm]
radeon_pci_probe+0x10f/0x1a0 [radeon]
pci_device_probe+0xd4/0x140
Fix the issue by updating all drivers which can access a platform provided
ROM. Instead of calling the helper function pci_platform_rom() which uses
phys_to_virt(), call ioremap() directly on the pdev->rom.
radeon_read_platform_bios() previously directly accessed an __iomem
pointer. Avoid this by calling memcpy_fromio() instead of kmemdup().
pci_platform_rom() now has no remaining callers, so remove it.
Link: https://lore.ker...
2020 Apr 11
0
[PATCH AUTOSEL 4.19 66/66] PCI: Use ioremap(), not phys_to_virt() for platform ROM
...nit+0x533/0xa50 [radeon]
radeon_driver_load_kms+0x80/0x220 [radeon]
drm_dev_register+0xa7/0x180 [drm]
radeon_pci_probe+0x10f/0x1a0 [radeon]
pci_device_probe+0xd4/0x140
Fix the issue by updating all drivers which can access a platform provided
ROM. Instead of calling the helper function pci_platform_rom() which uses
phys_to_virt(), call ioremap() directly on the pdev->rom.
radeon_read_platform_bios() previously directly accessed an __iomem
pointer. Avoid this by calling memcpy_fromio() instead of kmemdup().
pci_platform_rom() now has no remaining callers, so remove it.
Link: https://lore.ker...
2020 Mar 13
3
[PATCH RESEND v2 0/2] Fix loading of platform ROM from 32-bit EFI
This patch series fixes an oops when loading the radeon driver on old Macs
with a 32-bit EFI implementation.
Tested on a MacPro 1,1 with a Radeon X1900 XT card and 32-bit kernel.
Changes in v2:
- Add iounmap() call in nouveau
- Update function comment for pci_platform_rom()
- Minor changes to commit messages
Mikel Rychliski (2):
drm/radeon: Stop directly referencing iomem
PCI: Use ioremap(), not phys_to_virt() for platform ROM
drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c | 1 +
drivers/gpu/drm/nouveau/nvkm/subdev/bios/shadowpci.c | 11 ++++++++++-
d...
2020 Mar 05
2
[PATCH v2 0/2] Fix loading of platform ROM from 32-bit EFI
This patch series fixes an oops when loading the radeon driver on old Macs
with a 32-bit EFI implementation.
Tested on a MacPro 1,1 with a Radeon X1900 XT card and 32-bit kernel.
Mikel Rychliski (2):
drm/radeon: Stop directly referencing iomem
PCI: Use ioremap(), not phys_to_virt() for platform ROM
drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c | 1 +
2020 Mar 13
0
[PATCH RESEND v2 2/2] PCI: Use ioremap(), not phys_to_virt() for platform ROM
...? kmem_cache_alloc_trace+0x16f/0x220
? do_init_module+0x21/0x220
do_init_module+0x50/0x220
load_module+0x1f26/0x2200
sys_init_module+0x12d/0x160
do_fast_syscall_32+0x82/0x250
entry_SYSENTER_32+0xa5/0xf8
Fix the issue by using ioremap() instead of phys_to_virt() in
pci_platform_rom().
Now that pci_platform_rom() creates a new mapping to access the ROM
image, update all callers to remove this mapping after extracting the
BIOS.
Signed-off-by: Mikel Rychliski <mikel at mikelr.com>
---
drivers/gpu/drm/amd/amdgpu/amdgpu_bios.c | 1 +
drivers/gpu/drm/nouveau/n...
2020 Mar 18
0
[PATCH RESEND v2 2/2] PCI: Use ioremap(), not phys_to_virt() for platform ROM
...on).
Addressed in v2
On Tuesday, March 17, 2020 10:47:31 AM EDT Christoph Hellwig wrote:
> What is the value of this helper over just open coding an ioremap
> of pdev->rom in the callers?
I think the direct access to pdev->rom you suggest makes sense, especially
because users of the pci_platform_rom() are exposed to the fact that it just
calls ioremap().
I decided against wrapping the iounmap() with a pci_unmap_platform_rom(), but
I didn't apply the same consideration to the existing function.
How about something like this (with pci_platform_rom() removed)?
static bool radeon_read_pla...
2020 Mar 13
0
[PATCH RESEND v2 1/2] drm/radeon: Stop directly referencing iomem
pci_platform_rom() returns an __iomem pointer which should not be
accessed directly. Change radeon_read_platform_bios() to use
memcpy_fromio() instead of calling kmemdup() on the __iomem pointer.
Signed-off-by: Mikel Rychliski <mikel at mikelr.com>
---
drivers/gpu/drm/radeon/radeon_bios.c | 11 +++++++----...