armbian have support BPI-M2, have debian and ubuntu image for BPI-M2, cool working .
Common Debian Wheezy, Jessie or Ubuntu Trusty based. Compiled from scratch Root password is 1234. You will be prompted to change this password at first login First boot takes longer (around 3min) than usual (20s) because it updates package list, regenerates SSH keys and expand partition to fit your SD card. It will reboot one time automatically. Second boot also take little longer (around 3min) because it creates 128MB emergency swap space Ready to compile external modules. Tested with this wireless adapter Ethernet adapter with DHCP and SSH server ready on default port (22) Wireless adapter with DHCP ready if present but disabled (/etc/network/interfaces, WPA2: normal connect or AP mode) desktop environment upgrade ready NAND, SATA and USB install script included (/root) Serial console enabled Enabled automatic security update download for basic system and kernel. Upgrades are done via standard apt-get upgrade method Login script shows board name MOTD with current PMU temp, hard drive temp, ambient temp from Temper if exits, actual free memory & battery conditions.
Performance tweaks /tmp & /log = RAM, ramlog app saves logs to disk daily and on shut-down (Wheezy only) automatic IO scheduler. (check /etc/init.d/armhwinfo) journal data writeback enabled. (/etc/fstab) commit=600 to flush data to the disk every 10 minutes (/etc/fstab) optimized CPU frequency scaling 480-1010Mhz (392-996Mhz @Freescale) with interactive governor (/etc/init.d/cpufrequtils) eth0 interrupts are using dedicated core
Vanilla kernel Kernel 4.2.3 with large hardware support, headers and some firmware included IR functional and preconfigured – tested with LG remote Bluetooth ready (working with supported external keys) I2C ready and tested with small 16×2 LCD. Basic i2c tools included.
Bugs or limitation Jessie fails to boot on some boards. No audio or HW accelerated video NAND is not supported yet. Screen output from kernel is set to HDMI by default. Boot loader can detect and switch, kernel not.