History

dmaengine: ioatdma: constify dca_ops structures

The dca_ops structure is never modified, so declare it as const. Done with the help of Coccinelle.

Julia Lawall committed 11 years ago

Commit 2bb129e1 parent d3cd63f3 files · +6 −4Browse files

Showing the changes to include (1 of 3 files). Show all

Unified · Split

include/linux/dca.h+3−2
@@ -34,7 +34,7 @@ void dca_unregister_notify(struct notifier_block *nb); · 33 unmodified lines
3434
3535 struct dca_provider {
3636 struct list_head node;
37− struct dca_ops *ops;
37+ const struct dca_ops *ops;
3838 struct device *cd;
3939 int id;
4040 };
@@ -53,7 +53,8 @@ struct dca_ops { · 12 unmodified lines
5353 int (*dev_managed) (struct dca_provider *, struct device *);
5454 };
5555
56−struct dca_provider *alloc_dca_provider(struct dca_ops *ops, int priv_size);
56+struct dca_provider *alloc_dca_provider(const struct dca_ops *ops,
57+ int priv_size);
5758 void free_dca_provider(struct dca_provider *dca);
5859 int register_dca_provider(struct dca_provider *dca, struct device *dev);
5960 void unregister_dca_provider(struct dca_provider *dca, struct device *dev);