leds: pca955x: Drop platform data and allocate LEDs with the device
struct pca955x_platform_data has been private to this driver since commit ed1f4b9676a8 ("leds: pca955x: add device tree support"), so nothing can pass it in through dev_get_platdata() and it only serves as an intermediate copy of the per-LED type, default state and fwnode. That copy is a full array of struct pca955x_led, the same runtime structure that struct pca955x already holds, so the data is stored twice. Remove the platform data and parse the child firmware nodes directly into pca955x->leds[]. Make leds[] a flexible array member so it is allocated together with struct pca955x. This removes three allocations and the num_leds sanity check, which could no longer fail. struct pca955x_led moves above struct pca955x, as a flexible array member needs the complete element type. Assisted-by: LLM Signed-off-by: Rosen Penev <rosenp@gmail.com> Link: https://patch.msgid.link/20261005200906.188636-1-rosenp@gmail.com Signed-off-by: Lee Jones <lee@kernel.org>