Author Topic: 3.4.75+ kernel for CB2 and CT  (Read 5637 times)

Offline patwood

  • Linux geek
  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1660
  • Karma: +129/-0
    • View Profile
3.4.75+ kernel for CB2 and CT
« on: January 08, 2014, 11:00:27 pm »
I've uploaded a build of the 3.4.75 kernel that runs on both the Cubieboard2 and Cubietruck.  It's merged from the linux-sunxi/sunxi-3.4 branch of about December 23rd, and includes the Broadcom driver from Benn's 3.4.67 kernel (sunxi-3.4-ct-v101): http://dl.cubieforums.com/patwood/A20-kernel-3.4.75-ct.tar.gz

The git repository is here: https://github.com/patrickhwood/linux-sunxi/tree/pat-3.4.75-ct

What's working:

Gbit ethernet and wifi on CT (put bcmdhd in /etc/modules to auto load the driver)
100Mbit ethernet on CB2
CedarX
Mali
USB OTG (and g_ether)
GPIO, LED, all the other usual stuff

Note: sunxi-gmac and sunxi-emac are built in and don't need to be loaded on boot from /etc/modules.  Also, all the modules from my earlier kernels are still there, but most have not been tested on the CT.

What's not working:

Bluetooth on CT (maybe it is, but I can't get brcm_patchram_plus to cooperate). Edit: fixed.
8192cu driver refuses to load on the CT (works fine on CB2).

What's next:

1. updating the Broadcom driver to the latest version.
2. updating the branch to the latest stage/sunxi-3.4 version.
3. put together a single cubiuntu distro for CB2 and CT.
« Last Edit: January 13, 2014, 11:49:22 pm by patwood »

Offline patwood

  • Linux geek
  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1660
  • Karma: +129/-0
    • View Profile
Re: 3.4.75+ kernel for CB2 and CT
« Reply #1 on: January 13, 2014, 11:51:26 pm »
I have updated this download with two changes.  The first fixes Mali on the CT (there was a problem with physical memory addressing on boards with > 1GB of DRAM).  The second adds the hid-elecom.ko driver.
« Last Edit: January 14, 2014, 12:07:39 am by patwood »

fruit-bat

  • Guest
Re: 3.4.75+ kernel for CB2 and CT
« Reply #2 on: January 14, 2014, 03:55:08 pm »
Many thanks for posting.

I still seem to get issues with dpms... as in the monitor will power down but not back up again.
Anyone else having the same issue? Might just be something I messed up in the kernel build.

Anyhow, the following seems to fix it for me...

diff --git a/drivers/video/sunxi/disp/dev_disp.c b/drivers/video/sunxi/disp/dev_disp.c
index 9b59810..6562e26 100644
--- a/drivers/video/sunxi/disp/dev_disp.c
+++ b/drivers/video/sunxi/disp/dev_disp.c
@@ -548,7 +548,8 @@ int disp_suspend(int clk, int status)
       else if (suspend_output_type == DISP_OUTPUT_TYPE_HDMI)
          BSP_disp_hdmi_close(i);
    }
-   BSP_disp_clk_off(clk);
+// Clock does not seem to start again on resume!
+//   BSP_disp_clk_off(clk);
    suspend_status |= status;
 
    return 0;
@@ -560,7 +561,8 @@ int disp_resume(int clk, int status)
 
    __inf("disp_resume clk %d status %d call\n", clk, status);
 
-   BSP_disp_clk_on(clk);
+// Clock does not seem to start again on resume!
+//   BSP_disp_clk_on(clk);
 
    if (clk != 1)
    for (i = 0; i < 2; i++) {

Offline patwood

  • Linux geek
  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1660
  • Karma: +129/-0
    • View Profile
Re: 3.4.75+ kernel for CB2 and CT
« Reply #3 on: January 20, 2014, 11:10:18 pm »
Many thanks for posting.

I still seem to get issues with dpms... as in the monitor will power down but not back up again.
Anyone else having the same issue? Might just be something I messed up in the kernel build.

Anyhow, the following seems to fix it for me...

diff --git a/drivers/video/sunxi/disp/dev_disp.c b/drivers/video/sunxi/disp/dev_disp.c
index 9b59810..6562e26 100644
--- a/drivers/video/sunxi/disp/dev_disp.c
+++ b/drivers/video/sunxi/disp/dev_disp.c
@@ -548,7 +548,8 @@ int disp_suspend(int clk, int status)
       else if (suspend_output_type == DISP_OUTPUT_TYPE_HDMI)
          BSP_disp_hdmi_close(i);
    }
-   BSP_disp_clk_off(clk);
+// Clock does not seem to start again on resume!
+//   BSP_disp_clk_off(clk);
    suspend_status |= status;
 
    return 0;
@@ -560,7 +561,8 @@ int disp_resume(int clk, int status)
 
    __inf("disp_resume clk %d status %d call\n", clk, status);
 
-   BSP_disp_clk_on(clk);
+// Clock does not seem to start again on resume!
+//   BSP_disp_clk_on(clk);
 
    if (clk != 1)
    for (i = 0; i < 2; i++) {

Did you try

Code: [Select]
xset -dpms
?

Offline alexvf

  • Newbie
  • *
  • Posts: 7
  • Karma: +0/-0
    • View Profile
Re: 3.4.75+ kernel for CB2 and CT
« Reply #4 on: January 23, 2014, 04:28:58 am »
Or, if patwood's suggestion doesn't work, you can turn screensaver off

Code: [Select]
xset s off
as explained in http://linux-sunxi.org/Binary_drivers

Offline patwood

  • Linux geek
  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1660
  • Karma: +129/-0
    • View Profile
Re: 3.4.75+ kernel for CB2 and CT
« Reply #5 on: February 01, 2014, 07:35:20 pm »
I've uploaded a new build; it's described here: http://www.cubieforums.com/index.php/topic,1413.msg10360.html#msg10360

Offline johndoe_71rus

  • Full Member
  • ***
  • Posts: 242
  • Karma: +3/-1
    • View Profile
Re: 3.4.75+ kernel for CB2 and CT
« Reply #6 on: February 02, 2014, 12:25:20 am »
patwood
for cb2 need use sunxi_gmac.mac_str=XX:XX:XX:XX:XX:XX or can use old mac_addr?
Cubieboard2 / Android 4.2.2 / Cubieez 7.4@3.4.79+patwood

Offline patwood

  • Linux geek
  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1660
  • Karma: +129/-0
    • View Profile
Re: 3.4.75+ kernel for CB2 and CT
« Reply #7 on: February 02, 2014, 12:59:51 am »
patwood
for cb2 need use sunxi_gmac.mac_str=XX:XX:XX:XX:XX:XX or can use old mac_addr?

For CB2, the sunxi-emac driver is used, and it uses the old mac_addr kernel argument setting.