* acpica-fixes: ACPICA: Dispatcher: Update thread ID for recursive method calls * device-properties-fixes: device property: Avoid potential dereferences of invalid pointers
Showing the changes to include (2 of 3 files). Show all
Unified · Split
| @@ -394,13 +394,13 @@ struct acpi_data_node { · 393 unmodified lines | |||
| 394 | 394 | ||
| 395 | static inline bool is_acpi_node(struct fwnode_handle *fwnode) | 395 | static inline bool is_acpi_node(struct fwnode_handle *fwnode) |
| 396 | { | 396 | { |
| 397 | return fwnode && (fwnode->type == FWNODE_ACPI | 397 | return !IS_ERR_OR_NULL(fwnode) && (fwnode->type == FWNODE_ACPI |
| 398 | || fwnode->type == FWNODE_ACPI_DATA); | 398 | || fwnode->type == FWNODE_ACPI_DATA); |
| 399 | } | 399 | } |
| 400 | 400 | ||
| 401 | static inline bool is_acpi_device_node(struct fwnode_handle *fwnode) | 401 | static inline bool is_acpi_device_node(struct fwnode_handle *fwnode) |
| 402 | { | 402 | { |
| 403 | return fwnode && fwnode->type == FWNODE_ACPI; | 403 | return !IS_ERR_OR_NULL(fwnode) && fwnode->type == FWNODE_ACPI; |
| 404 | } | 404 | } |
| 405 | 405 | ||
| 406 | static inline struct acpi_device *to_acpi_device_node(struct fwnode_handle *fwnode) | 406 | static inline struct acpi_device *to_acpi_device_node(struct fwnode_handle *fwnode) |
| @@ -133,7 +133,7 @@ void of_core_init(void); · 132 unmodified lines | |||
| 133 | 133 | ||
| 134 | static inline bool is_of_node(struct fwnode_handle *fwnode) | 134 | static inline bool is_of_node(struct fwnode_handle *fwnode) |
| 135 | { | 135 | { |
| 136 | return fwnode && fwnode->type == FWNODE_OF; | 136 | return !IS_ERR_OR_NULL(fwnode) && fwnode->type == FWNODE_OF; |
| 137 | } | 137 | } |
| 138 | 138 | ||
| 139 | static inline struct device_node *to_of_node(struct fwnode_handle *fwnode) | 139 | static inline struct device_node *to_of_node(struct fwnode_handle *fwnode) |