Commit 91faa047 authored by Daniel Vetter's avatar Daniel Vetter

drm: drop extern from function decls

It's the default storage class for functions, entirely redundant. And
a lot of these headers are a bit inconsistent due to organically
grown.
Reviewed-by: default avatarGabriel Krisman Bertazi <krisman@collabora.co.uk>
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/20170322083617.13361-2-daniel.vetter@ffwll.ch
parent e448054b
...@@ -43,18 +43,18 @@ ...@@ -43,18 +43,18 @@
#include <drm/drm_modeset_helper_vtables.h> #include <drm/drm_modeset_helper_vtables.h>
#include <drm/drm_modeset_helper.h> #include <drm/drm_modeset_helper.h>
extern void drm_helper_disable_unused_functions(struct drm_device *dev); void drm_helper_disable_unused_functions(struct drm_device *dev);
extern int drm_crtc_helper_set_config(struct drm_mode_set *set); int drm_crtc_helper_set_config(struct drm_mode_set *set);
extern bool drm_crtc_helper_set_mode(struct drm_crtc *crtc, bool drm_crtc_helper_set_mode(struct drm_crtc *crtc,
struct drm_display_mode *mode, struct drm_display_mode *mode,
int x, int y, int x, int y,
struct drm_framebuffer *old_fb); struct drm_framebuffer *old_fb);
extern bool drm_helper_crtc_in_use(struct drm_crtc *crtc); bool drm_helper_crtc_in_use(struct drm_crtc *crtc);
extern bool drm_helper_encoder_in_use(struct drm_encoder *encoder); bool drm_helper_encoder_in_use(struct drm_encoder *encoder);
extern int drm_helper_connector_dpms(struct drm_connector *connector, int mode); int drm_helper_connector_dpms(struct drm_connector *connector, int mode);
extern void drm_helper_resume_force_mode(struct drm_device *dev); void drm_helper_resume_force_mode(struct drm_device *dev);
int drm_helper_crtc_mode_set(struct drm_crtc *crtc, struct drm_display_mode *mode, int drm_helper_crtc_mode_set(struct drm_crtc *crtc, struct drm_display_mode *mode,
struct drm_display_mode *adjusted_mode, int x, int y, struct drm_display_mode *adjusted_mode, int x, int y,
...@@ -63,15 +63,15 @@ int drm_helper_crtc_mode_set_base(struct drm_crtc *crtc, int x, int y, ...@@ -63,15 +63,15 @@ int drm_helper_crtc_mode_set_base(struct drm_crtc *crtc, int x, int y,
struct drm_framebuffer *old_fb); struct drm_framebuffer *old_fb);
/* drm_probe_helper.c */ /* drm_probe_helper.c */
extern int drm_helper_probe_single_connector_modes(struct drm_connector int drm_helper_probe_single_connector_modes(struct drm_connector
*connector, uint32_t maxX, *connector, uint32_t maxX,
uint32_t maxY); uint32_t maxY);
extern void drm_kms_helper_poll_init(struct drm_device *dev); void drm_kms_helper_poll_init(struct drm_device *dev);
extern void drm_kms_helper_poll_fini(struct drm_device *dev); void drm_kms_helper_poll_fini(struct drm_device *dev);
extern bool drm_helper_hpd_irq_event(struct drm_device *dev); bool drm_helper_hpd_irq_event(struct drm_device *dev);
extern void drm_kms_helper_hotplug_event(struct drm_device *dev); void drm_kms_helper_hotplug_event(struct drm_device *dev);
extern void drm_kms_helper_poll_disable(struct drm_device *dev); void drm_kms_helper_poll_disable(struct drm_device *dev);
extern void drm_kms_helper_poll_enable(struct drm_device *dev); void drm_kms_helper_poll_enable(struct drm_device *dev);
#endif #endif
...@@ -522,11 +522,11 @@ struct drm_driver { ...@@ -522,11 +522,11 @@ struct drm_driver {
int dev_priv_size; int dev_priv_size;
}; };
extern __printf(6, 7) __printf(6, 7)
void drm_dev_printk(const struct device *dev, const char *level, void drm_dev_printk(const struct device *dev, const char *level,
unsigned int category, const char *function_name, unsigned int category, const char *function_name,
const char *prefix, const char *format, ...); const char *prefix, const char *format, ...);
extern __printf(3, 4) __printf(3, 4)
void drm_printk(const char *level, unsigned int category, void drm_printk(const char *level, unsigned int category,
const char *format, ...); const char *format, ...);
extern unsigned int drm_debug; extern unsigned int drm_debug;
......
...@@ -45,9 +45,9 @@ struct drm_global_reference { ...@@ -45,9 +45,9 @@ struct drm_global_reference {
void (*release) (struct drm_global_reference *); void (*release) (struct drm_global_reference *);
}; };
extern void drm_global_init(void); void drm_global_init(void);
extern void drm_global_release(void); void drm_global_release(void);
extern int drm_global_item_ref(struct drm_global_reference *ref); int drm_global_item_ref(struct drm_global_reference *ref);
extern void drm_global_item_unref(struct drm_global_reference *ref); void drm_global_item_unref(struct drm_global_reference *ref);
#endif #endif
...@@ -49,17 +49,17 @@ struct drm_open_hash { ...@@ -49,17 +49,17 @@ struct drm_open_hash {
u8 order; u8 order;
}; };
extern int drm_ht_create(struct drm_open_hash *ht, unsigned int order); int drm_ht_create(struct drm_open_hash *ht, unsigned int order);
extern int drm_ht_insert_item(struct drm_open_hash *ht, struct drm_hash_item *item); int drm_ht_insert_item(struct drm_open_hash *ht, struct drm_hash_item *item);
extern int drm_ht_just_insert_please(struct drm_open_hash *ht, struct drm_hash_item *item, int drm_ht_just_insert_please(struct drm_open_hash *ht, struct drm_hash_item *item,
unsigned long seed, int bits, int shift, unsigned long seed, int bits, int shift,
unsigned long add); unsigned long add);
extern int drm_ht_find_item(struct drm_open_hash *ht, unsigned long key, struct drm_hash_item **item); int drm_ht_find_item(struct drm_open_hash *ht, unsigned long key, struct drm_hash_item **item);
extern void drm_ht_verbose_list(struct drm_open_hash *ht, unsigned long key); void drm_ht_verbose_list(struct drm_open_hash *ht, unsigned long key);
extern int drm_ht_remove_key(struct drm_open_hash *ht, unsigned long key); int drm_ht_remove_key(struct drm_open_hash *ht, unsigned long key);
extern int drm_ht_remove_item(struct drm_open_hash *ht, struct drm_hash_item *item); int drm_ht_remove_item(struct drm_open_hash *ht, struct drm_hash_item *item);
extern void drm_ht_remove(struct drm_open_hash *ht); void drm_ht_remove(struct drm_open_hash *ht);
/* /*
* RCU-safe interface * RCU-safe interface
......
...@@ -11,18 +11,18 @@ struct drm_encoder; ...@@ -11,18 +11,18 @@ struct drm_encoder;
struct device_node; struct device_node;
#ifdef CONFIG_OF #ifdef CONFIG_OF
extern uint32_t drm_of_find_possible_crtcs(struct drm_device *dev, uint32_t drm_of_find_possible_crtcs(struct drm_device *dev,
struct device_node *port); struct device_node *port);
extern void drm_of_component_match_add(struct device *master, void drm_of_component_match_add(struct device *master,
struct component_match **matchptr, struct component_match **matchptr,
int (*compare)(struct device *, void *), int (*compare)(struct device *, void *),
struct device_node *node); struct device_node *node);
extern int drm_of_component_probe(struct device *dev, int drm_of_component_probe(struct device *dev,
int (*compare_of)(struct device *, void *), int (*compare_of)(struct device *, void *),
const struct component_master_ops *m_ops); const struct component_master_ops *m_ops);
extern int drm_of_encoder_active_endpoint(struct device_node *node, int drm_of_encoder_active_endpoint(struct device_node *node,
struct drm_encoder *encoder, struct drm_encoder *encoder,
struct of_endpoint *endpoint); struct of_endpoint *endpoint);
#else #else
static inline uint32_t drm_of_find_possible_crtcs(struct drm_device *dev, static inline uint32_t drm_of_find_possible_crtcs(struct drm_device *dev,
struct device_node *port) struct device_node *port)
......
...@@ -39,17 +39,17 @@ struct drm_device; ...@@ -39,17 +39,17 @@ struct drm_device;
struct drm_driver; struct drm_driver;
struct drm_master; struct drm_master;
extern struct drm_dma_handle *drm_pci_alloc(struct drm_device *dev, size_t size, struct drm_dma_handle *drm_pci_alloc(struct drm_device *dev, size_t size,
size_t align); size_t align);
extern void drm_pci_free(struct drm_device *dev, struct drm_dma_handle * dmah); void drm_pci_free(struct drm_device *dev, struct drm_dma_handle * dmah);
extern int drm_pci_init(struct drm_driver *driver, struct pci_driver *pdriver); int drm_pci_init(struct drm_driver *driver, struct pci_driver *pdriver);
extern void drm_pci_exit(struct drm_driver *driver, struct pci_driver *pdriver); void drm_pci_exit(struct drm_driver *driver, struct pci_driver *pdriver);
#ifdef CONFIG_PCI #ifdef CONFIG_PCI
extern int drm_get_pci_dev(struct pci_dev *pdev, int drm_get_pci_dev(struct pci_dev *pdev,
const struct pci_device_id *ent, const struct pci_device_id *ent,
struct drm_driver *driver); struct drm_driver *driver);
extern int drm_pci_set_busid(struct drm_device *dev, struct drm_master *master); int drm_pci_set_busid(struct drm_device *dev, struct drm_master *master);
#else #else
static inline int drm_get_pci_dev(struct pci_dev *pdev, static inline int drm_get_pci_dev(struct pci_dev *pdev,
const struct pci_device_id *ent, const struct pci_device_id *ent,
...@@ -69,7 +69,7 @@ static inline int drm_pci_set_busid(struct drm_device *dev, ...@@ -69,7 +69,7 @@ static inline int drm_pci_set_busid(struct drm_device *dev,
#define DRM_PCIE_SPEED_50 2 #define DRM_PCIE_SPEED_50 2
#define DRM_PCIE_SPEED_80 4 #define DRM_PCIE_SPEED_80 4
extern int drm_pcie_get_speed_cap_mask(struct drm_device *dev, u32 *speed_mask); int drm_pcie_get_speed_cap_mask(struct drm_device *dev, u32 *speed_mask);
extern int drm_pcie_get_max_link_width(struct drm_device *dev, u32 *mlw); int drm_pcie_get_max_link_width(struct drm_device *dev, u32 *mlw);
#endif /* _DRM_PCI_H_ */ #endif /* _DRM_PCI_H_ */
...@@ -510,7 +510,7 @@ struct drm_plane { ...@@ -510,7 +510,7 @@ struct drm_plane {
#define obj_to_plane(x) container_of(x, struct drm_plane, base) #define obj_to_plane(x) container_of(x, struct drm_plane, base)
extern __printf(8, 9) __printf(8, 9)
int drm_universal_plane_init(struct drm_device *dev, int drm_universal_plane_init(struct drm_device *dev,
struct drm_plane *plane, struct drm_plane *plane,
uint32_t possible_crtcs, uint32_t possible_crtcs,
...@@ -519,13 +519,13 @@ int drm_universal_plane_init(struct drm_device *dev, ...@@ -519,13 +519,13 @@ int drm_universal_plane_init(struct drm_device *dev,
unsigned int format_count, unsigned int format_count,
enum drm_plane_type type, enum drm_plane_type type,
const char *name, ...); const char *name, ...);
extern int drm_plane_init(struct drm_device *dev, int drm_plane_init(struct drm_device *dev,
struct drm_plane *plane, struct drm_plane *plane,
uint32_t possible_crtcs, uint32_t possible_crtcs,
const struct drm_plane_funcs *funcs, const struct drm_plane_funcs *funcs,
const uint32_t *formats, unsigned int format_count, const uint32_t *formats, unsigned int format_count,
bool is_primary); bool is_primary);
extern void drm_plane_cleanup(struct drm_plane *plane); void drm_plane_cleanup(struct drm_plane *plane);
/** /**
* drm_plane_index - find the index of a registered plane * drm_plane_index - find the index of a registered plane
...@@ -538,8 +538,8 @@ static inline unsigned int drm_plane_index(struct drm_plane *plane) ...@@ -538,8 +538,8 @@ static inline unsigned int drm_plane_index(struct drm_plane *plane)
{ {
return plane->index; return plane->index;
} }
extern struct drm_plane * drm_plane_from_index(struct drm_device *dev, int idx); struct drm_plane * drm_plane_from_index(struct drm_device *dev, int idx);
extern void drm_plane_force_disable(struct drm_plane *plane); void drm_plane_force_disable(struct drm_plane *plane);
int drm_mode_plane_set_obj_prop(struct drm_plane *plane, int drm_mode_plane_set_obj_prop(struct drm_plane *plane,
struct drm_property *property, struct drm_property *property,
......
...@@ -57,24 +57,24 @@ struct drm_device; ...@@ -57,24 +57,24 @@ struct drm_device;
struct drm_gem_object; struct drm_gem_object;
struct drm_file; struct drm_file;
extern struct dma_buf *drm_gem_prime_export(struct drm_device *dev, struct dma_buf *drm_gem_prime_export(struct drm_device *dev,
struct drm_gem_object *obj, struct drm_gem_object *obj,
int flags); int flags);
extern int drm_gem_prime_handle_to_fd(struct drm_device *dev, int drm_gem_prime_handle_to_fd(struct drm_device *dev,
struct drm_file *file_priv, uint32_t handle, uint32_t flags, struct drm_file *file_priv, uint32_t handle, uint32_t flags,
int *prime_fd); int *prime_fd);
extern struct drm_gem_object *drm_gem_prime_import(struct drm_device *dev, struct drm_gem_object *drm_gem_prime_import(struct drm_device *dev,
struct dma_buf *dma_buf); struct dma_buf *dma_buf);
extern int drm_gem_prime_fd_to_handle(struct drm_device *dev, int drm_gem_prime_fd_to_handle(struct drm_device *dev,
struct drm_file *file_priv, int prime_fd, uint32_t *handle); struct drm_file *file_priv, int prime_fd, uint32_t *handle);
struct dma_buf *drm_gem_dmabuf_export(struct drm_device *dev, struct dma_buf *drm_gem_dmabuf_export(struct drm_device *dev,
struct dma_buf_export_info *exp_info); struct dma_buf_export_info *exp_info);
extern void drm_gem_dmabuf_release(struct dma_buf *dma_buf); void drm_gem_dmabuf_release(struct dma_buf *dma_buf);
extern int drm_prime_sg_to_page_addr_arrays(struct sg_table *sgt, struct page **pages, int drm_prime_sg_to_page_addr_arrays(struct sg_table *sgt, struct page **pages,
dma_addr_t *addrs, int max_pages); dma_addr_t *addrs, int max_pages);
extern struct sg_table *drm_prime_pages_to_sg(struct page **pages, unsigned int nr_pages); struct sg_table *drm_prime_pages_to_sg(struct page **pages, unsigned int nr_pages);
extern void drm_prime_gem_destroy(struct drm_gem_object *obj, struct sg_table *sg); void drm_prime_gem_destroy(struct drm_gem_object *obj, struct sg_table *sg);
#endif /* __DRM_PRIME_H__ */ #endif /* __DRM_PRIME_H__ */
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
* don't want to include the full drmP.h file. * don't want to include the full drmP.h file.
*/ */
extern int drm_class_device_register(struct device *dev); int drm_class_device_register(struct device *dev);
extern void drm_class_device_unregister(struct device *dev); void drm_class_device_unregister(struct device *dev);
#endif #endif
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