diff options
author | Ben Skeggs <bskeggs@redhat.com> | 2015-08-20 14:54:20 +1000 |
---|---|---|
committer | Ben Skeggs <bskeggs@redhat.com> | 2015-08-28 12:40:43 +1000 |
commit | 49bd8da5130aa2de1c891c71163a033254eaf932 (patch) | |
tree | 80f5bd05d1d3d2b233b36b3b45d71c130493302d /drivers/gpu/drm/nouveau/nvkm/subdev/i2c/nv50.c | |
parent | drm/nouveau/gpio: convert to new-style nvkm_subdev (diff) | |
download | linux-dev-49bd8da5130aa2de1c891c71163a033254eaf932.tar.xz linux-dev-49bd8da5130aa2de1c891c71163a033254eaf932.zip |
drm/nouveau/i2c: convert to new-style nvkm_subdev
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau/nvkm/subdev/i2c/nv50.c')
-rw-r--r-- | drivers/gpu/drm/nouveau/nvkm/subdev/i2c/nv50.c | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/i2c/nv50.c b/drivers/gpu/drm/nouveau/nvkm/subdev/i2c/nv50.c index 678585c44cb0..75640ab97d6a 100644 --- a/drivers/gpu/drm/nouveau/nvkm/subdev/i2c/nv50.c +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/i2c/nv50.c @@ -24,14 +24,13 @@ #include "priv.h" #include "pad.h" -struct nvkm_oclass * -nv50_i2c_oclass = &(struct nvkm_i2c_impl) { - .base.handle = NV_SUBDEV(I2C, 0x50), - .base.ofuncs = &(struct nvkm_ofuncs) { - .ctor = _nvkm_i2c_ctor, - .dtor = _nvkm_i2c_dtor, - .init = _nvkm_i2c_init, - .fini = _nvkm_i2c_fini, - }, +static const struct nvkm_i2c_func +nv50_i2c = { .pad_x_new = nv50_i2c_pad_new, -}.base; +}; + +int +nv50_i2c_new(struct nvkm_device *device, int index, struct nvkm_i2c **pi2c) +{ + return nvkm_i2c_new_(&nv50_i2c, device, index, pi2c); +} |