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 | 489 | struct list_head node; |
| 490 | 490 | struct iommu_domain *domain; |
| 491 | 491 | const char *name; |
| 492 | − char *firmware; | |
| 492 | + const char *firmware; | |
| 493 | 493 | void *priv; |
| 494 | 494 | struct rproc_ops *ops; |
| 495 | 495 | struct device dev; |