* Finalize all chips of statically known devices. * * This is the last call before calling the payload. This is a good place * to lock registers or other final cleanup. */
| 55 | * to lock registers or other final cleanup. |
| 56 | */ |
| 57 | void dev_finalize_chips(void) |
| 58 | { |
| 59 | const struct device *dev; |
| 60 | |
| 61 | for (dev = all_devices; dev; dev = dev->next) { |
| 62 | /* Initialize chip if we haven't yet. */ |
| 63 | if (dev->chip_ops && dev->chip_ops->final && |
| 64 | !dev->chip_ops->finalized) { |
| 65 | dev->chip_ops->final(dev->chip_info); |
| 66 | dev->chip_ops->finalized = 1; |
| 67 | } |
| 68 | } |
| 69 | } |
| 70 | |
| 71 | DECLARE_SPIN_LOCK(dev_lock) |
| 72 |