sun4i_wemac: Give the phy some time to settle after powering it on

This is necessary to avoid ending up with 10 Mbit half-duplex on
100 Mbit networks.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sun4i_wemac: Use random parts of SID for MAC (if none is specified)

So that the emac gets a unique *and* stable MAC address.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sun4i_wemac: Add wemac_set_mac_addr() helper function

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
rtl8188eu: Silence debug spew

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
rtl8189es: Silence debug spew

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
rtl8192cu: Silence debug spew

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi-disp: fb#_scaler_mode = 0 breaks interlaced modes, force to 1 for now

This is a temporary workaround, although depending on when someone finds
time to look into this it may not be so temporary ...

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sun4i_wemac: Do not use MAC from fex if it is 000000000000

Also improve MAC address logging:
-In case it comes from the cmdline, print the actual address after parsing,
 not the string from the kerne cmdline
-Log a message when using a MAC address from the fex file
-The fixed prefix for the MAC-address from the SID is 02 not 00

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi-hdmi: Don't warn twice on an invalid EDID checksum

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi-rfkill: Add support for usb-rfkill

Specifically add support for the usb_wifi_para section and esp. the
usb_wifi_gpio_power keyword. Without this the rtl8188ctv in the uhost-u1a
never gets power!

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Add arch/arm/mach-sun7i directory

This is a direct import of the sunxi-3.3-cb2 branch, minus:
-the rf stuff, as we have mmc_pm for that (same thing in a different form).
-the gpio stuff, as the a20 source dump uses the kernels official gpio
 mechanism for this now, but all our code wants the old gpio_request ext
 stuff, so we will use that from plat-sunxi (the pio controller seems
 unchanged)
-sys_config.c, as that was changed in ways incompatible with our existing code
 too.
-the cpu-freq-pmu and dram dirs, as they are unused

This is a temporary hack which will be hooked up with further commits, so as
to get sun7i support up and going using existing unified drivers for things
like the lcd/hdmi controller. Eventually this should be mostly unified too
and use arch/arm/plat-sunxi as much as possible.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sun7i: Hookup, make build and make run with serial console

After this commit is is possible to select sun7i in make config, build without
selecting any other sunxi specific devices, and then run on a serial console.

Next stop mmc support :)

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sun7i: Switch to using soc-detect.c

And also cleanup various headers to fix build breakage caused by the switch.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sun7i: Invert meaning of clk_reset reset parameter

The sun7i code from allwinner has changed the clk_reset function parameter
from an int to an enum, and that has the values (0 or 1) exactly reversed
of the previous parameters meaning.

Switch it back to how it was with sun4i / sun5i to avoid the need to add

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi-mmc: Add support for A20

Make sunxi-mmcm build (and work!) with sun7i as arch.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi-ehci/ohci: Add support for A20

And we've working USB (for the 2 regular controllers) !

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi-hdmi-cec: Do not define own highres counter functionality

This is unnecessary code duplication, and more over, the implementation is
wrong as it sets the latch bit, but does not wait for it to clear again
before reading the counter. Which causes hdmi_delay_us to hang on mach-sun7i.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
video-sunxi: Add A20 support

Tested on the cubieboard2, with several different dvi/hdmi monitors. Note
lcd / vga / composite out is not tested.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
video-sunxi: Fix interlaced modes being broken with the scaler disabled

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
sunxi-nand-compat: Fix compiler warning

Signed-off-by: Hans de Goede <hdegoede@redhat.com>