Re: [PATCH] mtd: maps: lantiq-flash: Check if the EBU endianness swap is enabled

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,


> I would prefer to use a device tree option to activate this check and
> only access LTQ_EBU_BUSCON0 when this property is set.

If I understand correctly, I have to make something like this :

---

bool mtd_addr_swap=true;

        if (!of_machine_is_compatible("lantiq,falcon") &&
                of_find_property(pdev->dev.of_node,
"lantiq,ebu_swap_check", NULL))
                if (ltq_ebu_r32(LTQ_EBU_BUSCON0) & EBU_FLASH_ENDIAN_SWAP)
                        mtd_addr_swap = false;

---

And then set this property directly on my device-specific dts file ?




[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux