Difference between revisions of "Kernel areas of focus for mainlining"
(→Wireless: add possible strategy for wireless driver) |
|||
(7 intermediate revisions by the same user not shown) | |||
Line 19: | Line 19: | ||
|-bgcolor="#80c0d0" | |-bgcolor="#80c0d0" | ||
!Manufacturer/phone/SoC => | !Manufacturer/phone/SoC => | ||
− | !LG/G3/Qcom !!Samsung/Galaxy 4/Exynos !!Acer/ | + | !LG/G3/Qcom !!Samsung/Galaxy 4/Exynos !!Acer/E2/Mediatek !!Asus/Zenfone 6/Atom !!Huawei/P6/Hisilicon !!Sony/Z3/Qcom |
|- | |- | ||
|Kernel area | |Kernel area | ||
Line 54: | Line 54: | ||
== Wireless == | == Wireless == | ||
+ | action item: Find out if any vendors have the same IP blocks for wireless | ||
+ | Here are the findings for 3.4: | ||
+ | * LG/G3/qcom - Broadcom 4330/4334/43341/4335/4339 | ||
+ | ** source include drivers/net/wireless/bcmdhd | ||
+ | *** this code is organized differently from the Acer bcmdhd code | ||
+ | |||
+ | * Samsung/Galaxy 4/exynos - Broadcom 4335 | ||
+ | ** source includes drivers/net/wireless/bcmdhd | ||
+ | ** source includes drivers/net/wireless/ipsecdrvtl | ||
+ | |||
+ | * Acer/E2/mediatek - Broadcom 4329/30 wireless chipsets | ||
+ | ** source includes drivers/net/wireless/bcmdhd | ||
+ | ** mainline 4.2 has drivers/net/wireless/brcm80211/brcmfmac,brcmsmac,brcmutil | ||
+ | ** !! also lots of code in mdtk/krnl/drivers/combo/drv_wlan/mt66s*/wlan/mgmt,nic,os/linux | ||
+ | *** code under this tree is not in linux format (it has vendor style) | ||
+ | *** need to see if this is some mediatek on-chip thing, and Acer added external broadcom chip for E2 | ||
+ | |||
+ | * Asus/Zenfone 6/Atom - Broadcom 4329/30 | ||
+ | ** source include drivers/net/wireless/bcmdhd | ||
+ | |||
+ | * Huawei/P6/Hisilicon | ||
+ | ** defines CONFIG_WL12XX=m | ||
+ | |||
+ | * Sony/Z3/Qcom - | ||
+ | ** Sony has historically used broadcom 4339 and qcom 3660 and qcom 3680. | ||
+ | |||
+ | Random notes: | ||
+ | * Google got burned in early Android - TI had a bad wireless implementation (it was cross-platform and didn't work well in Linux). Google now integrates broadcom code themselves, at drivers/net/wireless/brcmdhd, and requires current Android vendors to use broadcom. This explains why everyone has it. | ||
+ | * broadcom driver in mainline is a drivers/net/wireless/brcm80211/* | ||
+ | ** this is the one people should try to use and extend if it doesn't work | ||
+ | |||
+ | Possible strategy: | ||
+ | * backport brcm80211 code to 3.18 or 3.14. These are the versions of kernels likely to be used in the next generation of Android products. Having the brcm80211 code available in that version means that phone vendors can test the driver. If it's close to product grade, they can help improve it - if not, then they can report the issues upstream. | ||
+ | ** Is Google or someone else already doing this - AI - check 3.18 src from SoC vendor for brcm80211 code | ||
+ | |||
+ | skeleton for other comparisons: | ||
+ | * LG/G3/qcom - | ||
+ | * Samsung/Galaxy 4/exynos - | ||
+ | * Acer/E2/mediatek - | ||
+ | * Asus/Zenfone 6/Atom - | ||
+ | * Huawei/P6/Hisilicon - | ||
+ | * Sony/Z3/qcom - | ||
== Sound == | == Sound == |
Revision as of 15:44, 30 July 2015
This page has a list of areas of the kernel where multiple SoCs have code out-of-tree, or that appear to need some work in order to accommodate contribution of device-related software.
Contents
Overview
The following table shows major out-of-tree areas of code, for mobile phone products based on the 3.4 Linux kernel. Although this kernel is quite old, it was the one currently shipping in phones in late 2014 and early 2015, when this analysis was done. It demonstrates the major technical areas where vendors used out-of-tree kernel code, for that generation of products.
The table shows different phones, and the number of lines they have out-of-mainline for several different kernel areas. The analysis was done using the upstream-analysis-tools (See https://github.com/tbird20d/upstream-analysis-tools). Since this task was mostly automated, the results here should not be considered definitive. That is, most of the categorization of diffs was done using regex matches on the file paths. Although this can result in some mis-categorizations of diffs, the results appear to show general patterns which may be of interest.
Note that the table shows the number of insertions (or changes). The number of deletions was found to be inconsequential for this analysis.
Manufacturer/phone/SoC => | LG/G3/Qcom | Samsung/Galaxy 4/Exynos | Acer/E2/Mediatek | Asus/Zenfone 6/Atom | Huawei/P6/Hisilicon | Sony/Z3/Qcom |
---|---|---|---|---|---|---|
Kernel area | ||||||
Mach specific | 417411 | 89118 | ? | ? | ? | 393767 |
Media | 131811 | 163540 | ? | 1466714 | 153032 | 124973 |
Video | 221550 | 176787 | 37876 | 38785 | 238267 | 214027 |
Wireless | 110946 | 123308 | 387214 | 91449 | 122501 | 81502 |
Sound | 216643 | 86127 | 12932 | 74057 | 19250 | 213137 |
Input | 107334 | 51160 | 2752 | 53321 | 35410 | 62930 |
Camera | 66989 | 1342 | 7900 | 1024348 | 51065 | 56744 |
GPU | 53345 | 172300 | 114932 | 36545 | 198323 | 53468 |
Power | 61912 | 7635 | 94059 | 66629 | 45127 | 46173 |
USB | 99295 | 35366 | 30795 | 34074 | 121075 | 98663 |
Notable other | Prima - 565210 | firmware - 101069 | i2c - 105744 | reg - 90034 |
Technical areas
Here are some lists of things to get mainlined, in different technical areas:
Media
Video
Wireless
action item: Find out if any vendors have the same IP blocks for wireless Here are the findings for 3.4:
- LG/G3/qcom - Broadcom 4330/4334/43341/4335/4339
- source include drivers/net/wireless/bcmdhd
- this code is organized differently from the Acer bcmdhd code
- source include drivers/net/wireless/bcmdhd
- Samsung/Galaxy 4/exynos - Broadcom 4335
- source includes drivers/net/wireless/bcmdhd
- source includes drivers/net/wireless/ipsecdrvtl
- Acer/E2/mediatek - Broadcom 4329/30 wireless chipsets
- source includes drivers/net/wireless/bcmdhd
- mainline 4.2 has drivers/net/wireless/brcm80211/brcmfmac,brcmsmac,brcmutil
- !! also lots of code in mdtk/krnl/drivers/combo/drv_wlan/mt66s*/wlan/mgmt,nic,os/linux
- code under this tree is not in linux format (it has vendor style)
- need to see if this is some mediatek on-chip thing, and Acer added external broadcom chip for E2
- Asus/Zenfone 6/Atom - Broadcom 4329/30
- source include drivers/net/wireless/bcmdhd
- Huawei/P6/Hisilicon
- defines CONFIG_WL12XX=m
- Sony/Z3/Qcom -
- Sony has historically used broadcom 4339 and qcom 3660 and qcom 3680.
Random notes:
- Google got burned in early Android - TI had a bad wireless implementation (it was cross-platform and didn't work well in Linux). Google now integrates broadcom code themselves, at drivers/net/wireless/brcmdhd, and requires current Android vendors to use broadcom. This explains why everyone has it.
- broadcom driver in mainline is a drivers/net/wireless/brcm80211/*
- this is the one people should try to use and extend if it doesn't work
Possible strategy:
- backport brcm80211 code to 3.18 or 3.14. These are the versions of kernels likely to be used in the next generation of Android products. Having the brcm80211 code available in that version means that phone vendors can test the driver. If it's close to product grade, they can help improve it - if not, then they can report the issues upstream.
- Is Google or someone else already doing this - AI - check 3.18 src from SoC vendor for brcm80211 code
skeleton for other comparisons:
- LG/G3/qcom -
- Samsung/Galaxy 4/exynos -
- Acer/E2/mediatek -
- Asus/Zenfone 6/Atom -
- Huawei/P6/Hisilicon -
- Sony/Z3/qcom -
Sound
Input
Camera
GPU
Power
USB
- USB-gadget to charger interface
- Currently in progress at Linaro.
- Code for external vbus and ID detection (looks like extcon was created for stuff like this - ish, it's mainly a mainlining of the Android switch API though it probably does fit)
Notes from ksummit-discuss list
- RGB leds - not the same as 3 leds, and sometimes have hardware acceleration
- battery over-discharge protection
- charger (there are 3 different chargers on N900)
- voice link to modem (Nokia says ALSA is not suitable for modem audio)
- No need for this, ALSA is in active use for rather a lot of production phones...
- userspace (mini-distro?) for testing
- suspend-to-ram