Fix Linux build. Why won't this complile? extern int const foo; static

struct drm_driver driver = { .var = foo }; error says foo is not
    constant
This commit is contained in:
Jon Smirl 2004-11-06 16:41:24 +00:00
parent b2f275b46e
commit 000c8eb18e
2 changed files with 4 additions and 3 deletions

View file

@ -88,8 +88,7 @@ static struct drm_driver driver = {
.get_reg_ofs = drm_core_get_reg_ofs,
.postinit = postinit,
.version = version,
.ioctls = ioctls,
.num_ioctls = DRM_ARRAY_SIZE(ioctls),
.ioctls = r128_ioctls,
.dma_ioctl = r128_cce_buffers,
.fops = {
.owner = THIS_MODULE,
@ -116,6 +115,8 @@ static int probe(struct pci_dev *pdev, const struct pci_device_id *ent)
static int __init r128_init(void)
{
driver.num_ioctls = r128_max_ioctl;
return drm_init(&driver, pciidlist);
}

View file

@ -94,7 +94,6 @@ static struct drm_driver driver = {
.postinit = postinit,
.version = version,
.ioctls = radeon_ioctls,
.num_ioctls = DRM_ARRAY_SIZE(radeon_ioctls),
.dma_ioctl = radeon_cp_buffers,
.fops = {
.owner = THIS_MODULE,
@ -120,6 +119,7 @@ static int probe(struct pci_dev *pdev, const struct pci_device_id *ent)
static int __init radeon_init(void)
{
driver.num_ioctls = radeon_max_ioctl;
return drm_init(&driver, pciidlist);
}