FreeBSD on X1 Carbon (Gen 6)

From Run Your Own
Revision as of 19:34, 29 November 2018 by 320x200 (talk | contribs)
Jump to navigation Jump to search

Base Installation

  • grab ISO
  • encryption info goes here

Tracking FreeBSD-STABLE 12

/etc/src/conf - source build options

WITHOUT_ASSERT_DEBUG=true # compile without the assert(3) checks.
WITHOUT_AUDIT=true # Set to not build audit support into system programs.
WITHOUT_BSNMP=true # Set to not build or install bsnmpd(1)
WITHOUT_CALENDAR=true # Set to not build calendar(1)
#WITHOUT_LIB32=true
WITHOUT_TESTS=true # Set to not build nor install the FreeBSD Test Suite
WITHOUT_INET6=true
#WITHOUT_CROSS_COMPILER=true
#WITHOUT_KERBEROS=true # some pkgs do not like to have it without
WITHOUT_MAIL=true
WITHOUT_QUOTAS=true
WITHOUT_DEBUG_FILES=true
WITH_SVN=true # Set to install svnlite(1) as svn(1).

/etc/make.conf - system build information

CPUTYPE?=skylake           # no kabylake yet?

FreeBSD source and installation

rm -rf /usr/src/*
svnlite checkout https://svn0.eu.FreeBSD.org/base/stable/12 /usr/src

Hardware Specific config

BIOS Updates

  • Get latest BIOS update from Lenovo as bootable CD ISO file.
  • Convert the ISO to something that you can boot from USB
geteltorito -o usb-bios-update.img n23ur13w.is
  • Write the image to your USB device
sudo dd if=usb-bios-update.img of=/dev/sdc bs=10M
  • plug USB in X1, (re)boot
  • Press enter, then F12 to choose temporary startup device
  • Choose your USB device (USB HDD)
  • Follow instructions from BIOS update utility

WiFi

  • in /etc/rc.conf
# Wireless
wlans_iwm0="wlan0"
background_dhclient="YES"
ifconfig_wlan0="WPA DHCP country NL"

GPU

DRM Next Kernel Module

  • Install the port
portmaster -i graphics/drm-next-kmod
  • in /etc/rc.conf
# drm-next-kmod port
kld_list="/boot/modules/i915kms.ko"
  • add your main user to video group
pw usermod ${USERNAME} -G video
  • reboot
shutdown -r now

Xorg

  • /etc/X11/xorg.conf
Section "Device"
  Identifier  "Intel Graphics"
  Driver      "intel"
  Option      "TearFree" "true"
EndSection

Note: These days all the useful options are enabled by default so no need to add too many extra parameters.

Thinkpad drivers

Used for LCD control, suspend, etc...

  • in /boot/loader.conf
# Thinkpad stuff
acpi_video_load="YES"
acpi_ibm_load="YES"

Optional

  • Don't want some options, /etc/make.conf
OPTIONS_SET+=SNDIO      # BSD specific sound system
 
OPTIONS_UNSET+=DOCS     # I only install specific ones
OPTIONS_UNSET+=EXAMPLES # Same
OPTIONS_UNSET+=IPV6     # IPV6 free laptop already saved the day twice
  • Keyboard rate
xset rate r rate 250 34
kbdcontrol -r fast
  • in /etc/sysctl.conf
# No BEEPS!
hw.syscons.bell=0
kern.vt.enable_bell=0
  • If you don't like the touchpad and only use the emblematic Thinkpad pointing stick, you can disable the touchpad entirely in the BIOS (hurray!)
  • in ~/.login.conf
me:\
        :charset=UTF-8:\
        :lang=en_GB.UTF-8:\
        :setenv=LC_COLLATE=C:
  • in /etc/rc.conf
dbus_enable="YES"       # Enable DBUS
dumpdev="NO"            # Disable crash dumps

References