Commit 0b3b72df authored by Mauro Carvalho Chehab's avatar Mauro Carvalho Chehab

[media] media_entity: remove gfp_flags argument

We should not be creating device nodes at IRQ contexts. So,
the only flags we'll be using will be GFP_KERNEL. Let's
remove the gfp_flags, in order to make the interface simpler.

If we ever need it, it would be easy to revert those changes.

While here, remove an extra blank line.
Suggested-by: default avatarSakari Ailus <sakari.ailus@iki.fi>
Acked-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@osg.samsung.com>
parent 8ed07142
...@@ -394,8 +394,7 @@ static int dvb_register_media_device(struct dvb_device *dvbdev, ...@@ -394,8 +394,7 @@ static int dvb_register_media_device(struct dvb_device *dvbdev,
dvbdev->intf_devnode = media_devnode_create(dvbdev->adapter->mdev, dvbdev->intf_devnode = media_devnode_create(dvbdev->adapter->mdev,
intf_type, 0, intf_type, 0,
DVB_MAJOR, minor, DVB_MAJOR, minor);
GFP_KERNEL);
if (!dvbdev->intf_devnode) if (!dvbdev->intf_devnode)
return -ENOMEM; return -ENOMEM;
......
...@@ -866,12 +866,11 @@ static void media_interface_init(struct media_device *mdev, ...@@ -866,12 +866,11 @@ static void media_interface_init(struct media_device *mdev,
struct media_intf_devnode *media_devnode_create(struct media_device *mdev, struct media_intf_devnode *media_devnode_create(struct media_device *mdev,
u32 type, u32 flags, u32 type, u32 flags,
u32 major, u32 minor, u32 major, u32 minor)
gfp_t gfp_flags)
{ {
struct media_intf_devnode *devnode; struct media_intf_devnode *devnode;
devnode = kzalloc(sizeof(*devnode), gfp_flags); devnode = kzalloc(sizeof(*devnode), GFP_KERNEL);
if (!devnode) if (!devnode)
return NULL; return NULL;
......
...@@ -786,8 +786,7 @@ static int video_register_media_controller(struct video_device *vdev, int type) ...@@ -786,8 +786,7 @@ static int video_register_media_controller(struct video_device *vdev, int type)
vdev->intf_devnode = media_devnode_create(vdev->v4l2_dev->mdev, vdev->intf_devnode = media_devnode_create(vdev->v4l2_dev->mdev,
intf_type, intf_type,
0, VIDEO_MAJOR, 0, VIDEO_MAJOR,
vdev->minor, vdev->minor);
GFP_KERNEL);
if (!vdev->intf_devnode) { if (!vdev->intf_devnode) {
media_device_unregister_entity(&vdev->entity); media_device_unregister_entity(&vdev->entity);
return -ENOMEM; return -ENOMEM;
......
...@@ -71,7 +71,6 @@ struct media_gobj { ...@@ -71,7 +71,6 @@ struct media_gobj {
struct list_head list; struct list_head list;
}; };
struct media_pipeline { struct media_pipeline {
}; };
...@@ -378,8 +377,7 @@ void media_entity_pipeline_stop(struct media_entity *entity); ...@@ -378,8 +377,7 @@ void media_entity_pipeline_stop(struct media_entity *entity);
struct media_intf_devnode * struct media_intf_devnode *
__must_check media_devnode_create(struct media_device *mdev, __must_check media_devnode_create(struct media_device *mdev,
u32 type, u32 flags, u32 type, u32 flags,
u32 major, u32 minor, u32 major, u32 minor);
gfp_t gfp_flags);
void media_devnode_remove(struct media_intf_devnode *devnode); void media_devnode_remove(struct media_intf_devnode *devnode);
struct media_link * struct media_link *
__must_check media_create_intf_link(struct media_entity *entity, __must_check media_create_intf_link(struct media_entity *entity,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment