On Fri, Dec 11, 2020 at 11:54 AM Souptick Joarder <jrdr.linux(a)gmail.com> wrote:
of_device_get_match_data() returns void * which is assigned to enum
imx_dma_type type without extracting
the value. Anything wrong with the previous assignment ?
The driver data is now passed via:
imxdma->devtype = (enum imx_dma_type)of_device_get_match_data(&pdev->dev);
There was nothing wrong with the previous assignment.
The original driver used to run on non-DT platforms. Now it only runs
on DT-platforms, which means we no longer need the platform data
structure.
Please note that this a W=1 clang warning. gcc does not complain about it.
Not sure how to make clang happy in this case.
The (enum ....)of_device_get_match_data() cast is widely used in the
kernel, so this is not specific usage in this driver.