Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b3a83639 authored by Dave Airlie's avatar Dave Airlie Committed by Dave Airlie
Browse files

drm: fix all sparse warning on 32-bit x86



Finally cleaned up the sparse warnings for the drm.

Signed-off-by: default avatarDave Airlie <airlied@linux.ie>
parent 689b9d74
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -117,7 +117,7 @@ static __inline__ unsigned int HandleID(unsigned long lhandle,
 * type.  Adds the map to the map list drm_device::maplist. Adds MTRR's where
 * applicable and if supported by the kernel.
 */
int drm_addmap_core(drm_device_t * dev, unsigned int offset,
static int drm_addmap_core(drm_device_t * dev, unsigned int offset,
			   unsigned int size, drm_map_type_t type,
			   drm_map_flags_t flags, drm_map_list_t ** maplist)
{
+2 −2
Original line number Diff line number Diff line
@@ -232,7 +232,7 @@ int drm_getsareactx(struct inode *inode, struct file *filp,
	map = dev->context_sareas[request.ctx_id];
	up(&dev->struct_sem);

	request.handle = 0;
	request.handle = NULL;
	list_for_each_entry(_entry, &dev->maplist->head, head) {
		if (_entry->map == map) {
			request.handle =
@@ -240,7 +240,7 @@ int drm_getsareactx(struct inode *inode, struct file *filp,
			break;
		}
	}
	if (request.handle == 0)
	if (request.handle == NULL)
		return -EINVAL;

	if (copy_to_user(argp, &request, sizeof(request)))
+0 −3
Original line number Diff line number Diff line
@@ -74,9 +74,6 @@ static struct pci_device_id pciidlist[] = {
	i810_PCI_IDS
};

extern drm_ioctl_desc_t i810_ioctls[];
extern int i810_max_ioctl;

static struct drm_driver driver = {
	.driver_features =
	    DRIVER_USE_AGP | DRIVER_REQUIRE_AGP | DRIVER_USE_MTRR |
+3 −0
Original line number Diff line number Diff line
@@ -121,6 +121,9 @@ extern void i810_driver_pretakedown(drm_device_t * dev);
extern void i810_driver_prerelease(drm_device_t * dev, DRMFILE filp);
extern int i810_driver_device_is_agp(drm_device_t * dev);

extern drm_ioctl_desc_t i810_ioctls[];
extern int i810_max_ioctl;

#define I810_BASE(reg)		((unsigned long) \
				dev_priv->mmio_map->handle)
#define I810_ADDR(reg)		(I810_BASE(reg) + reg)
+0 −3
Original line number Diff line number Diff line
@@ -75,9 +75,6 @@ static struct pci_device_id pciidlist[] = {
	i830_PCI_IDS
};

extern drm_ioctl_desc_t i830_ioctls[];
extern int i830_max_ioctl;

static struct drm_driver driver = {
	.driver_features =
	    DRIVER_USE_AGP | DRIVER_REQUIRE_AGP | DRIVER_USE_MTRR |
Loading