Re: [PATCH V3 1/2] mtd: allow getting MTD device associated with a specific DT node

2022-06-14 Thread Ahmad Fatoum
Hello Rafał, On 11.06.22 22:46, Rafał Miłecki wrote: > From: Rafał Miłecki > > MTD subsystem API allows interacting with MTD devices (e.g. reading, > writing, handling bad blocks). So far a random driver could get MTD > device only by its name (get_mtd_device_nm()). This change allows > getting

Re: [PATCH V3 1/2] mtd: allow getting MTD device associated with a specific DT node

2022-06-13 Thread Miquel Raynal
Hi Rafał, zaj...@gmail.com wrote on Mon, 13 Jun 2022 16:15:34 +0200: > On 13.06.2022 16:04, Miquel Raynal wrote: > >> @@ -1154,6 +1154,34 @@ int __get_mtd_device(struct mtd_info *mtd) > >> } > >> EXPORT_SYMBOL_GPL(__get_mtd_device); > >> >> +/** > >> + * of_get_mtd_device_by_node -

Re: [PATCH V3 1/2] mtd: allow getting MTD device associated with a specific DT node

2022-06-13 Thread Rafał Miłecki
On 13.06.2022 16:04, Miquel Raynal wrote: @@ -1154,6 +1154,34 @@ int __get_mtd_device(struct mtd_info *mtd) } EXPORT_SYMBOL_GPL(__get_mtd_device); +/** + * of_get_mtd_device_by_node - obtain an MTD device associated with a given node + * + * @np: device tree node + */ +struct mtd_info

Re: [PATCH V3 1/2] mtd: allow getting MTD device associated with a specific DT node

2022-06-13 Thread Miquel Raynal
Hi Rafał, zaj...@gmail.com wrote on Sat, 11 Jun 2022 22:46:50 +0200: > From: Rafał Miłecki > > MTD subsystem API allows interacting with MTD devices (e.g. reading, > writing, handling bad blocks). So far a random driver could get MTD > device only by its name (get_mtd_device_nm()). This change

[PATCH V3 1/2] mtd: allow getting MTD device associated with a specific DT node

2022-06-11 Thread Rafał Miłecki
From: Rafał Miłecki MTD subsystem API allows interacting with MTD devices (e.g. reading, writing, handling bad blocks). So far a random driver could get MTD device only by its name (get_mtd_device_nm()). This change allows getting them also by a DT node. This API is required for drivers