For cases where @firmware is declared "const char *", use function kstrdup_const() to avoid needlessly creating another copy on the heap.
Showing the changes to include/linux (1 of 2 files). Show all
Unified · Split
| @@ -489,7 +489,7 @@ struct rproc { · 488 unmodified lines | |||
| 489 | struct list_head node; | 489 | struct list_head node; |
| 490 | struct iommu_domain *domain; | 490 | struct iommu_domain *domain; |
| 491 | const char *name; | 491 | const char *name; |
| 492 | char *firmware; | 492 | const char *firmware; |
| 493 | void *priv; | 493 | void *priv; |
| 494 | struct rproc_ops *ops; | 494 | struct rproc_ops *ops; |
| 495 | struct device dev; | 495 | struct device dev; |