Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

N950 and N9 initial ports #121

Closed
dderby opened this issue Apr 20, 2018 · 10 comments
Closed

N950 and N9 initial ports #121

dderby opened this issue Apr 20, 2018 · 10 comments

Comments

@dderby
Copy link
Member

dderby commented Apr 20, 2018

I'm opening this ticket to track the N950 and N9 ports and to provide initial documentation.

The following pull requests have been merged:

maemo-leste-upstream-forks/xorg-server#1
maemo-leste/hildon-meta#1
parazyd/arm-sdk#4
maemo-leste/image-builder#3
maemo-leste/image-builder#4

All testing was done on the N950. The N9 port is completely untested at this moment in time. I've taken hardware differences between the two devices into consideration and have customised the N9 port accordingly.

The port is based on linux-stable 4.16. Kernel patches come from Sebastian Reichel's (@sre) patch series "[PATCHv2 0/8] omapdrm: DSI command mode panel support" and Filip Matijević's (@filippz) patches for postmarketOS. I've created an additional patch for the N950 DT to fix the default orientation for fbcon. I've added the patchwork client to make it easy to apply patches that have been posted to mailing lists (more info here). I've now removed pwclient in order to avoid using an additional remote dependency which would be prone to failure.

The ports can be installed on the devices' eMMC and will boot with ubiboot. An initrd is not provided nor required. I have not tested the .img file, but the .tar.gz file can be unpacked to a unused slice formatted as ext4.

I'm using a preinit script to kick the watchdogs which again was based on Filip's work for postmarketOS. ubiboot will need to be configured to use /sbin/preinit. This has a side effect in that it creates kernel messages every 2 seconds and floods the console. It may be desirable to reduce the loglevel until this is fixed.

Wi-Fi is not yet working however USB networking works fine. Similar to previous Maemo versions, the USB network interface usb0 has been configured with a static IP of 192.168.2.15 and expects to find a gateway on 192.168.2.14. You should be able to connect to it via SSH and have it route through your computer after running the following commands:

# ifconfig usb0 up 192.168.2.14
# iptables -A POSTROUTING -t nat -s 192.168.2.15/32 -j MASQUERADE

The N950 X11 keyboard layout is taken from Harmattan and has been configured to work with the console as well. At some point I'd like to try and get this upstreamed.

Battery charging does not work yet.

Like the Droid 4 port, this needs Tony Lindgren's (@tmlind) patch for Xorg to be able to rotate the screen. Even with the patched Xorg, rotation in Hildon Desktop is still broken however I have tested it with other window managers and it works fine.

When the display is rotated correctly, the touchscreen works perfectly out of the box and does not appear need any calibration in userspace. The Atmel maXTouch configuration file for the N950 was dumped from my device and the one for the N9 comes from Filip's postmarketOS port.

@MerlijnWajer
Copy link
Member

Sweet! Have you spoken to @pavelmachek about some of the parts that you say are currently missing? He might have it working.

@pavelmachek
Copy link

I got sound to work and then some minor details. I did get battery status, but not battery charging. I suggest N900 or Droid4 as better target machine.

@MerlijnWajer
Copy link
Member

@pavelmachek: Thanks for the info. regarding better targets, understood. I also believe those are better supported targets and more easy to get for developers. (I don't have a N9 or N950 sadly). I do think the work @dderby to make the work of himself and others available as a port is cool, so I'd be happy if he continues with that.

@pavelmachek
Copy link

So.. I have the hardware and am to willing to help... a bit :-). But Droid 4 currently has a priority, as it is very close to be usable. My linux-n900 tree on kernel.org has patches for N9/N950, too.

@dderby
Copy link
Member Author

dderby commented Apr 20, 2018

I'm in agreement that there are better targets and to be honest I don't want to spend too much more of my time on this either. I did these ports mainly for a couple of reasons:

  1. I want to try and generate more interest in the project amongst the Maemo community and perhaps pick up a few more contributors, either for Maemo Leste or mainline Linux. There are plenty of people on talk.maemo.org who still have N9s (and a few with N950s). I hope someone will look at fixing the Hildon rotation problem which I haven't been able to figure out.
  2. There so few devices with decent mainline Linux support that if work we're going to promote Maemo Leste as a multi-device distro built on top mainline Linux, it make sense have these ports available.

I'd like to now start focusing my time on other things like wiki documentation of the boot process, documentation of devices supported by mainline Linux, and maybe do a Nexus 5 port which has several advantages over existing targets. I will however review @pavelmachek's linux-n900 tree to see what we can use.

@parazyd
Copy link
Member

parazyd commented Apr 25, 2018

The N9 and N950 images are up today. I'm closing this.

Please open specific tickets for further things related to these devices :)

@parazyd parazyd closed this as completed Apr 25, 2018
@sixaxis
Copy link

sixaxis commented Apr 28, 2018

Hello, friends! I have an H950 and I want to help. Can I help financially? I'm a programmer, but I've never built a kernel and modules. Now I am actively studying this topic and setting up the necessary tools. Can you explain the grave difficulties in porting the kernel? How do I guess the main problem is the closed source code of some drivers?
How will I see the progress of the project? Thank you and good luck to all of us!

@dderby
Copy link
Member Author

dderby commented Apr 28, 2018

Hi @sixaxis,

The available builds for the N950 include a pre-built kernel and modules. The first thing you'll want to do is make sure you can get this up and running. To do this, you'll need to install ubiboot, repartition the eMMC and unpack the .tar.gz dist to a fresh ext4 partition.

Images are built using the image-builder: https://github.com/maemo-leste/image-builder
Documentation is a little bit lacking at the moment but the information here should help to get you started: maemo-leste/image-builder#2

I wouldn't say that there are any grave difficulties in porting the kernel. The key thing that is missing is the PowerVR kernel interface to use the hardware accelerated video closed drivers. Apart from video and GPS, all of the drivers are already available in mainline Linux and are only missing device tree entries to be able to use some of these drivers. More info here: https://elinux.org/N950

As for the general project progress, status updates are periodically posted here: https://maemo-leste.github.io/category/news.html

For the latest happenings, please come and join us on IRC: chat.freenode.net, channel #maemo-leste.

@dderby
Copy link
Member Author

dderby commented May 4, 2018

@sixaxis, I've written up some details on how to configure ubiboot here.

@sixaxis
Copy link

sixaxis commented May 17, 2018 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants