summaryrefslogtreecommitdiffstats
path: root/docs/misc
diff options
context:
space:
mode:
Diffstat (limited to 'docs/misc')
-rw-r--r--docs/misc/index.html262
-rw-r--r--docs/misc/patch.html305
2 files changed, 303 insertions, 264 deletions
diff --git a/docs/misc/index.html b/docs/misc/index.html
index f4e7836..a4e0aba 100644
--- a/docs/misc/index.html
+++ b/docs/misc/index.html
@@ -13,74 +13,82 @@
<body>
- <h1 id="pagetop">Miscellaneous</h1>
- <p>
- Or <a href="../index.html">Back to main index</a>.
- </p>
- <ul>
- <li><a href="#high_pitch_trisquel">High Pitched Whining Noise on Idle (how to remove in Trisquel)</a>
- <ul>
- <li><a href="#howtouse_powertop">Powertop - how to use</a></li>
- <li><a href="#powertop_autostart">Powertop - Start automatically at boot time</a></li>
- </ul>
- </li>
- <li><a href="#high_pitch_parabola">High Pitched Whining Noise on Idle (how to remove in Parabola)</a></li>
- <li><a href="#serial">X60/T60: Serial port - how to use (for dock owners)</a></li>
- <li><a href="patch.html">Using diff and patch</a></li>
- <li><a href="#get_edid_panelname">Get EDID: Find out the name (model) of your LCD panel</a></li>
- </ul>
-
-<hr/>
-
- <h1 id="high_pitch_trisquel">High Pitched Whining Noise on Idle (how to remove in Trisquel)</h1>
+ <div class="section">
+ <h1 id="pagetop">Miscellaneous</h1>
+ <p>
+ Or <a href="../index.html">Back to main index</a>.
+ </p>
+ <ul>
+ <li><a href="#high_pitch_trisquel">High Pitched Whining Noise on Idle (how to remove in Trisquel)</a>
+ <ul>
+ <li><a href="#howtouse_powertop">Powertop - how to use</a></li>
+ <li><a href="#powertop_autostart">Powertop - Start automatically at boot time</a></li>
+ </ul>
+ </li>
+ <li><a href="#high_pitch_parabola">High Pitched Whining Noise on Idle (how to remove in Parabola)</a></li>
+ <li><a href="#serial">X60/T60: Serial port - how to use (for dock owners)</a></li>
+ <li><a href="patch.html">Using diff and patch</a></li>
+ <li><a href="#get_edid_panelname">Get EDID: Find out the name (model) of your LCD panel</a></li>
+ </ul>
+ </div>
- <p>
- Tested in Trisquel 6 and 7.
- </p>
+ <div class="section">
- <h2 id="howtouse_powertop">Powertop - how to use</h2>
+ <h1 id="high_pitch_trisquel">High Pitched Whining Noise on Idle (how to remove in Trisquel)</h1>
- <p>Now you can use this command to kill that noise:<br/>
- <b>$ sudo powertop --auto-tune</b></p>
+ <p>
+ Tested in Trisquel 6 and 7.
+ </p>
- <p>You can also run it without parameters and then go into 'Tunables' and set everything to 'Good'</p>
+ <div class="subsection">
+ <h2 id="howtouse_powertop">Powertop - how to use</h2>
- <p>Note: On Trisquel 6, you will need to use a later powertop version from git. The one in the repositories is too old. See below:</p>
+ <p>Now you can use this command to kill that noise:<br/>
+ <b>$ sudo powertop --auto-tune</b></p>
- <h2 id="powertop_autostart">Powertop - Start automatically at boot time (Trisquel 6)</h2>
+ <p>You can also run it without parameters and then go into 'Tunables' and set everything to 'Good'</p>
- <p>Included with libreboot is a script called 'powertop.trisquel6'. Run this and it will setup powertop to run with --auto-tune
- at boot time. Load the file in your text editor to see how it does that.</p>
+ <p>Note: On Trisquel 6, you will need to use a later powertop version from git. The one in the repositories is too old. See below:</p>
+ </div>
- <p><b>$ ./powertop.trisquel6</b></p>
+ <div class="subsection">
+ <h2 id="powertop_autostart">Powertop - Start automatically at boot time (Trisquel 6)</h2>
- <p>For Trisquel 7 users:</p>
- <p><b>$ ./powertop.trisquel7</b></p>
+ <p>Included with libreboot is a script called 'powertop.trisquel6'. Run this and it will setup powertop to run with --auto-tune
+ at boot time. Load the file in your text editor to see how it does that.</p>
- <p><a href="#pagetop">Back to top of page</a></p>
+ <p><b>$ ./powertop.trisquel6</b></p>
-<hr/>
+ <p>For Trisquel 7 users:</p>
+ <p><b>$ ./powertop.trisquel7</b></p>
+ </div>
- <h1 id="high_pitch_parabola">High Pitched Whining Noise on Idle (how to remove in Parabola)</h1>
+ <p><a href="#pagetop">Back to top of page</a></p>
+
+ </div>
- <p>The following removes most of the noise. It reduces what is a high frequency whine
- (that not everyone can hear) to a slight buzz (which most people can't hear or doesn't bother most people).</p>
+ <div class="section">
- <p>This is not perfect! The full solution is still not discovered but this is a step towards that.
- Also, in some instances you will need to run 'sudo powertop --auto-tune' again.
- This needs to be implemented properly in coreboot itself!</p>
+ <h1 id="high_pitch_parabola">High Pitched Whining Noise on Idle (how to remove in Parabola)</h1>
- <p>On the X60 with coreboot or libreboot, there is a high pitched sound when idle.
- So far we have use processor.max_cstate=2 or idle=halt in GRUB.
- These consume power. Stop using them! </p>
+ <p>The following removes most of the noise. It reduces what is a high frequency whine
+ (that not everyone can hear) to a slight buzz (which most people can't hear or doesn't bother most people).</p>
- <p>Be root<br/>
- <b>$ su -</b></p>
+ <p>This is not perfect! The full solution is still not discovered but this is a step towards that.
+ Also, in some instances you will need to run 'sudo powertop --auto-tune' again.
+ This needs to be implemented properly in coreboot itself!</p>
- <p>Installed powertop:<br/>
- <b># pacman -S powertop</b></p>
+ <p>On the X60 with coreboot or libreboot, there is a high pitched sound when idle.
+ So far we have use processor.max_cstate=2 or idle=halt in GRUB.
+ These consume power. Stop using them! </p>
- <p>and added the following to /etc/systemd/system/powertop.service :</p>
+ <p>Be root<br/>
+ <b>$ su -</b></p>
+
+ <p>Installed powertop:<br/>
+ <b># pacman -S powertop</b></p>
+
+ <p>and added the following to /etc/systemd/system/powertop.service :</p>
<pre><i>
[Unit]
@@ -98,85 +106,93 @@ WantedBy=multi-user.target
</i></pre>
- <p>Finally, as root do that:<br/>
- <b># systemctl enable powertop</b><br/>
- <b># systemctl start powertop</b></p>
-
- <p>The next time you boot the machine, the buzz will be gone.</p>
-
- <p><a href="#pagetop">Back to top of page</a></p>
+ <p>Finally, as root do that:<br/>
+ <b># systemctl enable powertop</b><br/>
+ <b># systemctl start powertop</b></p>
+
+ <p>The next time you boot the machine, the buzz will be gone.</p>
+
+ <p><a href="#pagetop">Back to top of page</a></p>
+
+ </div>
+
+ <div class="section">
+
+ <h1 id="serial">X60/T60: Serial port - how to use (for dock owners)</h1>
+ <p>
+ For the Thinkpad X60 you can use the <b>&quot;UltraBase X6&quot;</b> dock (for the X60 Tablet it is called
+ X6 Tablet UltraBase). For the ThinkPad T60,
+ you can use the <b>&quot;Advanced Mini Dock&quot;</b>.
+ </p>
+ <p>
+ If you are using one of the ROM images with 'serial' in the name, then you have serial port enabled in libreboot
+ and you have memtest86+ included inside the ROM. Connect your null modem cable to the serial port on the dock
+ and connect the other end to a 2nd machine using your USB Serial adapter.
+ </p>
+ <p>
+ On the 2nd machine, you can try this (using GNU Screen):<br/>
+ <b>$ sudo screen /dev/ttyUSB0 115200</b>
+ </p>
+ <p>
+ How to quit GNU Screen: Ctrl+A then release and press K, and then press Y.
+ </p>
+ <p>There are also others like Minicom but I like GNU Screen</p>
+ <p>
+ By doing this before booting the X60/T60, you will see console output from libreboot. You will also see
+ GRUB displaying on the serial output, and you will be able to see MemTest86+ on the serial output aswell.
+ You can also configure your distro so that a terminal (TTY) is accessible from the serial console.
+ </p>
+ <p>
+ The following guide is for Ubuntu, and can be followed for Trisquel 6.0 which is based on Ubuntu 12.04
+ (should also work in Trisquel 7, based on Ubuntu 14.04) to enable a serial console using GeTTY:<br/>
+ <a href="https://help.ubuntu.com/community/SerialConsoleHowto">https://help.ubuntu.com/community/SerialConsoleHowto</a>
+ </p>
+ <p>
+ Note: part of the tutorial above requires changing your grub.cfg. Just change the <b>linux</b> line to add instructions for enabling getty.
+ See <a href="../gnulinux/grub_cbfs.html">../gnulinux/grub_cbfs.html</a>.
+ </p>
+ <p><a href="#pagetop">Back to top of page</a>
+
+ </div>
+
+ <div class="section">
+
+ <h1 id="get_edid_panelname">Get EDID: Find out the name (model) of your LCD panel</h1>
+ <p>
+ Get the panel name with <b>sudo get-edid | strings</b><br/>
+ Or look in <b>/sys/class/drm/card0-LVDS-1/edid</b>
+ </p>
+ <p>
+ Alternatively you can use i2cdump. In Trisquel, this is in the package i2c-tools.<br/>
+ $ <b>sudo modprobe i2c-dev</b><br/>
+ $ <b>sudo i2cdump -y 5 0x50</b><br/>
+ $ <b>sudo rmmod i2c-dev</b><br/>
+ You'll see the panel name in the output (from the EDID dump).
+ </p>
+ <p>
+ If neither of these options work (or they are unavailable), physically removing the LCD panel is an option.
+ Usually, there will be information printed on the back.
+ </p>
+
+ <p><a href="#pagetop">Back to top of page.</a></p>
+
+ </div>
+
+ <div class="section">
-<hr/>
-
- <h1 id="serial">X60/T60: Serial port - how to use (for dock owners)</h1>
- <p>
- For the Thinkpad X60 you can use the <b>&quot;UltraBase X6&quot;</b> dock (for the X60 Tablet it is called
- X6 Tablet UltraBase). For the ThinkPad T60,
- you can use the <b>&quot;Advanced Mini Dock&quot;</b>.
- </p>
- <p>
- If you are using one of the ROM images with 'serial' in the name, then you have serial port enabled in libreboot
- and you have memtest86+ included inside the ROM. Connect your null modem cable to the serial port on the dock
- and connect the other end to a 2nd machine using your USB Serial adapter.
- </p>
- <p>
- On the 2nd machine, you can try this (using GNU Screen):<br/>
- <b>$ sudo screen /dev/ttyUSB0 115200</b>
- </p>
<p>
- How to quit GNU Screen: Ctrl+A then release and press K, and then press Y.
+ Copyright &copy; 2014, 2015 Francis Rowe &lt;info@gluglug.org.uk&gt;<br/>
+ This document is released under the Creative Commons Attribution-ShareAlike 4.0 International Public License and all future versions.
+ A copy of the license can be found at <a href="../license.txt">../license.txt</a>.
</p>
- <p>There are also others like Minicom but I like GNU Screen</p>
- <p>
- By doing this before booting the X60/T60, you will see console output from libreboot. You will also see
- GRUB displaying on the serial output, and you will be able to see MemTest86+ on the serial output aswell.
- You can also configure your distro so that a terminal (TTY) is accessible from the serial console.
- </p>
- <p>
- The following guide is for Ubuntu, and can be followed for Trisquel 6.0 which is based on Ubuntu 12.04
- (should also work in Trisquel 7, based on Ubuntu 14.04) to enable a serial console using GeTTY:<br/>
- <a href="https://help.ubuntu.com/community/SerialConsoleHowto">https://help.ubuntu.com/community/SerialConsoleHowto</a>
- </p>
- <p>
- Note: part of the tutorial above requires changing your grub.cfg. Just change the <b>linux</b> line to add instructions for enabling getty.
- See <a href="../gnulinux/grub_cbfs.html">../gnulinux/grub_cbfs.html</a>.
- </p>
- <p><a href="#pagetop">Back to top of page</a>
-<hr/>
-
- <h1 id="get_edid_panelname">Get EDID: Find out the name (model) of your LCD panel</h1>
<p>
- Get the panel name with <b>sudo get-edid | strings</b><br/>
- Or look in <b>/sys/class/drm/card0-LVDS-1/edid</b>
+ This document is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See <a href="../license.txt">../license.txt</a> for more information.
</p>
- <p>
- Alternatively you can use i2cdump. In Trisquel, this is in the package i2c-tools.<br/>
- $ <b>sudo modprobe i2c-dev</b><br/>
- $ <b>sudo i2cdump -y 5 0x50</b><br/>
- $ <b>sudo rmmod i2c-dev</b><br/>
- You'll see the panel name in the output (from the EDID dump).
- </p>
- <p>
- If neither of these options work (or they are unavailable), physically removing the LCD panel is an option.
- Usually, there will be information printed on the back.
- </p>
-
- <p><a href="#pagetop">Back to top of page.</a></p>
-
-<hr/>
-
- <p>
- Copyright &copy; 2014 Francis Rowe &lt;info@gluglug.org.uk&gt;<br/>
- This document is released under the Creative Commons Attribution-ShareAlike 4.0 International Public License and all future versions.
- A copy of the license can be found at <a href="../license.txt">../license.txt</a>.
- </p>
-
- <p>
- This document is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See <a href="../license.txt">../license.txt</a> for more information.
- </p>
+
+ </div>
</body>
</html>
diff --git a/docs/misc/patch.html b/docs/misc/patch.html
index 3d926ac..681fdfb 100644
--- a/docs/misc/patch.html
+++ b/docs/misc/patch.html
@@ -6,7 +6,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1">
<style type="text/css">
- @import url('css/main.css');
+ @import url('../css/main.css');
</style>
<title>
@@ -17,147 +17,170 @@
<body>
- <header>
+ <div class="section">
<h1 id="pagetop">Diff and patch</h1>
- <aside>This is just a quick guide for reference, use 'man' to know more.</aside>
- </header>
-
- <p>
- <a href="index.html">back to index</a>
- </p>
-
-<hr/>
-
- <h1>
- Apply a patch
- </h1>
-
- <p class="important">
- To apply a patch to a single file, do that in it's directory:<br/>
- <b>$ patch &lt; foo.patch</b>
- </p>
-
- <p>
- Assuming that the patch is distributed in unified format identifying
- the file the patch should be applied to, the above will work. Otherwise:<br/>
- <b>$ patch foo.txt &lt; bar.patch</b>
- </p>
-
- <p>
- You can apply a patch to an entire directory, but note the &quot;p level&quot;.
- What this means is that inside patch files will be the files that you
- intend to patch, identified by path names that might be different
- when the files ane located on your own computer instead of on the computer
- where the patch was created. 'p' level instructs the 'patch' utility to
- ignore parts of the path name to identify the files correctly. Usually a
- p level of 1 will work, so you would use:<br/>
- <b>$ patch -p1 &lt; baz.patch</b>
- </p>
-
- <p>
- Change to the top level directory before running this. If a patch level
- of 1 cannot identify the files to patch, then inspect the patch file for file names.
- For example:<br/>
- <b>/home/user/do/not/panic/yet.c</b>
- </p>
-
- <p>
- and you are working in a directory that contains panic/yet.c, use:<br/>
- <b>$ patch -p5 &lt; baz.patch</b>
- </p>
-
- <p>
- You usually count one up for each path separator (forward slash)
- removed from the beginning of the path, until you are left with a path
- that exists in the current working directory. The count is the p level.
- </p>
-
- <p>
- Removing a patch using the -R flag<br/>
- <b>$ patch -p5 -R &lt; baz.patch</b>
- </p>
-
- <p><a href="#pagetop">Back to top of page.</a></p>
-
-<hr/>
-
- <h1>
- Create a patch with diff
- </h1>
-
- <p>
- Diff can create a patch for a single file:<br/>
- <b>$ diff -u original.c new.c &gt; original.patch</b>
- </p>
-
- <p>
- For diff'ing a source tree:<br/>
- <b>$ cp -R original new</b>
- </p>
-
- <p>
- Do whatever you want in new/ and then diff it:<br/>
- <b>$ diff -rupN original/ new/ &gt; original.patch</b>
- </p>
-
- <p><a href="#pagetop">Back to top of page.</a></p>
-
-<hr/>
-
- <h1>
- git diff
- </h1>
-
- <p>
- git is something special.
- </p>
-
- <p>
- Just make whatever changes you want to a git clone and then:<br/>
- <b>$ git diff &gt; patch.git</b>
- </p>
-
- <p>
- Note the git revision that you did this with:<br/>
- <b>$ git log</b>
- </p>
-
- <p><a href="#pagetop">Back to top of page.</a></p>
-
-<hr/>
-
- <h1>
- git apply
- </h1>
-
- <p>it really is.</p>
-
- <p>
- Now to apply that patch in the future, just git clone it again and do
- with the git revision you found from above:<br/>
- <b>$ git reset --hard REVISIONNUMBER</b>
- </p>
-
- <p>
- Now put patch.git in the git clone directory and do:<br/>
- <b>$ git apply patch.git</b>
- </p>
-
- <p><a href="#pagetop">Back to top of page.</a></p>
-
-<hr/>
-
- <p>
- Copyright &copy; 2014 Francis Rowe &lt;info@gluglug.org.uk&gt;<br/>
- This document is released under the Creative Commons Attribution-ShareAlike 4.0 International Public License and all future versions.
- A copy of the license can be found at <a href="../license.txt">../license.txt</a>.
- </p>
-
- <p>
- This document is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See <a href="../license.txt">../license.txt</a> for more information.
- </p>
+ <p>This is just a quick guide for reference, use 'man' to know more.</p>
+ <p>
+ <a href="index.html">Back to index</a>
+ </p>
+ </div>
+
+ <div class="section">
+
+ <h1>
+ Apply a patch
+ </h1>
+
+ <p class="important">
+ To apply a patch to a single file, do that in it's directory:<br/>
+ <b>$ patch &lt; foo.patch</b>
+ </p>
+
+ <p>
+ Assuming that the patch is distributed in unified format identifying
+ the file the patch should be applied to, the above will work. Otherwise:<br/>
+ <b>$ patch foo.txt &lt; bar.patch</b>
+ </p>
+
+ <p>
+ You can apply a patch to an entire directory, but note the &quot;p level&quot;.
+ What this means is that inside patch files will be the files that you
+ intend to patch, identified by path names that might be different
+ when the files ane located on your own computer instead of on the computer
+ where the patch was created. 'p' level instructs the 'patch' utility to
+ ignore parts of the path name to identify the files correctly. Usually a
+ p level of 1 will work, so you would use:<br/>
+ <b>$ patch -p1 &lt; baz.patch</b>
+ </p>
+
+ <p>
+ Change to the top level directory before running this. If a patch level
+ of 1 cannot identify the files to patch, then inspect the patch file for file names.
+ For example:<br/>
+ <b>/home/user/do/not/panic/yet.c</b>
+ </p>
+
+ <p>
+ and you are working in a directory that contains panic/yet.c, use:<br/>
+ <b>$ patch -p5 &lt; baz.patch</b>
+ </p>
+
+ <p>
+ You usually count one up for each path separator (forward slash)
+ removed from the beginning of the path, until you are left with a path
+ that exists in the current working directory. The count is the p level.
+ </p>
+
+ <p>
+ Removing a patch using the -R flag<br/>
+ <b>$ patch -p5 -R &lt; baz.patch</b>
+ </p>
+
+ <p><a href="#pagetop">Back to top of page.</a></p>
+
+ </div>
+
+ <div class="section">
+
+ <h1>
+ Create a patch with diff
+ </h1>
+
+ <p>
+ Diff can create a patch for a single file:<br/>
+ <b>$ diff -u original.c new.c &gt; original.patch</b>
+ </p>
+
+ <p>
+ For diff'ing a source tree:<br/>
+ <b>$ cp -R original new</b>
+ </p>
+
+ <p>
+ Do whatever you want in new/ and then diff it:<br/>
+ <b>$ diff -rupN original/ new/ &gt; original.patch</b>
+ </p>
+
+ <p><a href="#pagetop">Back to top of page.</a></p>
+
+ </div>
+
+ <div class="section">
+
+ <h1>
+ git diff
+ </h1>
+
+ <p>
+ git is something special.
+ </p>
+ <p>
+ Note: this won't show new files created.
+ </p>
+
+ <p>
+ Just make whatever changes you want to a git clone and then:<br/>
+ <b>$ git diff &gt; patch.git</b>
+ </p>
+
+ <p>
+ Note the git revision that you did this with:<br/>
+ <b>$ git log</b>
+ </p>
+
+ <p>
+ Alternatively (better yet), commit your changes and then use:<br/>
+ $ <b>git format-patch -N</b><br/>
+ Replace N with the number of commits that you want to show.
+ </p>
+
+ <p><a href="#pagetop">Back to top of page.</a></p>
+
+ </div>
+
+ <div class="section">
+
+ <h1>
+ git apply
+ </h1>
+
+ <p>it really is.</p>
+
+ <p>
+ Now to apply that patch in the future, just git clone it again and do
+ with the git revision you found from above:<br/>
+ <b>$ git reset --hard REVISIONNUMBER</b>
+ </p>
+
+ <p>
+ Now put patch.git in the git clone directory and do:<br/>
+ <b>$ git apply patch.git</b>
+ </p>
+
+ <p>
+ If you use a patch from git format-patch, then use <b>git am patch.git</b> instead of <b>git apply patch.git</b>. git-am
+ will re-create the commits aswell, instead of just applying the patch.
+ </p>
+
+ <p><a href="#pagetop">Back to top of page.</a></p>
+
+ </div>
+
+ <div class="section">
+
+ <p>
+ Copyright &copy; 2014, 2015 Francis Rowe &lt;info@gluglug.org.uk&gt;<br/>
+ This document is released under the Creative Commons Attribution-ShareAlike 4.0 International Public License and all future versions.
+ A copy of the license can be found at <a href="../license.txt">../license.txt</a>.
+ </p>
+
+ <p>
+ This document is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See <a href="../license.txt">../license.txt</a> for more information.
+ </p>
+
+ </div>
</body>
</html>