summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFathi Boudra <fathi.boudra@linaro.org>2013-04-13 09:15:05 +0300
committerFathi Boudra <fathi.boudra@linaro.org>2013-04-13 09:15:05 +0300
commitcf164afd8de42aa3bd856bcaa50719f5742532d9 (patch)
tree421f3721d984a860b940d9433acbaf0318c45a05
Imported Debian version 0.2debian/0.2
-rw-r--r--debian/changelog16
-rw-r--r--debian/compat1
-rw-r--r--debian/control14
-rw-r--r--debian/copyright24
-rwxr-xr-xdebian/rules4
-rw-r--r--debian/source/format1
-rw-r--r--debian/ubuntu-vexpress-extras-config.postinst40
-rw-r--r--debian/ubuntu-vexpress-extras-config.postrm38
-rw-r--r--debian/ubuntu-vexpress-extras-config.upstart27
9 files changed, 165 insertions, 0 deletions
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..442a256
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,16 @@
+ubuntu-vexpress-extras-config (0.2) precise; urgency=low
+
+ [ Jon Medhurst (Tixy) ]
+ * Add upstart job to set cpufreq governor as we want for big.LITTLE
+ * Add postinst/postrm scripts to disable the ondemand job so it
+ doesn't mess with our settings.
+ * Remove all use of cpufrequtils, it didn't help us with what we're
+ trying to achieve.
+
+ -- Ricardo Salveti de Araujo <ricardo.salveti@linaro.org> Tue, 25 Sep 2012 00:49:06 -0300
+
+ubuntu-vexpress-extras-config (0.1) precise; urgency=low
+
+ * Initial release
+
+ -- Ricardo Salveti de Araujo <ricardo.salveti@linaro.org> Sat, 08 Sep 2012 20:54:47 -0300
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 0000000..ec63514
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+9
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..6aeef8d
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,14 @@
+Source: ubuntu-vexpress-extras-config
+Section: utils
+Priority: extra
+Maintainer: Linaro Developers <linaro-dev@lists.linaro.org>
+Build-Depends: debhelper (>= 9)
+Standards-Version: 3.9.3
+Vcs-Bzr: https://code.launchpad.net/~linaro-maintainers/linaro-ubuntu/ubuntu-vexpress-extras-config
+
+Package: ubuntu-vexpress-extras-config
+Architecture: all
+Depends: ${misc:Depends}
+Description: This is the ARM vexpress configuration package
+ It provides additinal configuration files and settings for a better
+ vexpress usage with Ubuntu.
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 0000000..dcffdb1
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,24 @@
+Author: Ricardo Salveti <ricardo.salveti@linaro.org>
+
+Copyright:
+
+License (everything else):
+
+ Copyright (C) 2011 Linaro Ltd. <http://www.linaro.org/>
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program 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 the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+
+On Debian and Ubuntu systems, the complete text of the GNU General Public License
+can be found in /usr/share/common-licenses/GPL file.
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000..a5e0d78
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,4 @@
+#! /usr/bin/make -f
+
+%:
+ dh $@
diff --git a/debian/source/format b/debian/source/format
new file mode 100644
index 0000000..89ae9db
--- /dev/null
+++ b/debian/source/format
@@ -0,0 +1 @@
+3.0 (native)
diff --git a/debian/ubuntu-vexpress-extras-config.postinst b/debian/ubuntu-vexpress-extras-config.postinst
new file mode 100644
index 0000000..cc39315
--- /dev/null
+++ b/debian/ubuntu-vexpress-extras-config.postinst
@@ -0,0 +1,40 @@
+#!/bin/sh
+# postinst script for #PACKAGE#
+#
+# see: dh_installdeb(1)
+
+set -e
+
+# summary of how this script can be called:
+# * <postinst> `configure' <most-recently-configured-version>
+# * <old-postinst> `abort-upgrade' <new version>
+# * <conflictor's-postinst> `abort-remove' `in-favour' <package>
+# <new-version>
+# * <postinst> `abort-remove'
+# * <deconfigured's-postinst> `abort-deconfigure' `in-favour'
+# <failed-install-package> <version> `removing'
+# <conflicting-package> <version>
+# for details, see http://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+
+
+case "$1" in
+ configure)
+ update-rc.d ondemand disable || true
+ ;;
+
+ abort-upgrade|abort-remove|abort-deconfigure)
+ ;;
+
+ *)
+ echo "postinst called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
diff --git a/debian/ubuntu-vexpress-extras-config.postrm b/debian/ubuntu-vexpress-extras-config.postrm
new file mode 100644
index 0000000..e6de902
--- /dev/null
+++ b/debian/ubuntu-vexpress-extras-config.postrm
@@ -0,0 +1,38 @@
+#!/bin/sh
+# postrm script for #PACKAGE#
+#
+# see: dh_installdeb(1)
+
+set -e
+
+# summary of how this script can be called:
+# * <postrm> `remove'
+# * <postrm> `purge'
+# * <old-postrm> `upgrade' <new-version>
+# * <new-postrm> `failed-upgrade' <old-version>
+# * <new-postrm> `abort-install'
+# * <new-postrm> `abort-install' <old-version>
+# * <new-postrm> `abort-upgrade' <old-version>
+# * <disappearer's-postrm> `disappear' <overwriter>
+# <overwriter-version>
+# for details, see http://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+
+
+case "$1" in
+ purge|remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
+ update-rc.d ondemand enable || true
+ ;;
+
+ *)
+ echo "postrm called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
diff --git a/debian/ubuntu-vexpress-extras-config.upstart b/debian/ubuntu-vexpress-extras-config.upstart
new file mode 100644
index 0000000..f0aa4c0
--- /dev/null
+++ b/debian/ubuntu-vexpress-extras-config.upstart
@@ -0,0 +1,27 @@
+start on runlevel [12345]
+
+task
+
+script
+ # Setup cpufeq
+ #
+ # We want to setup big cores to 'performance' and LITTLE cores
+ # to 'ondemand' but currently there isn't any way to determine
+ # which is which. So what we'll do for now is:
+ # a) assume that N big cores are numbered 0..N-1 and LITTLE
+ # cores are N..
+ # b) assume that N<=4
+ # c) all cores in a cluster have the same cpufreq driver, so
+ # that setting the frequency of one CPU also sets the others.
+ # With these assumptions, the following will set the LITTLE
+ # cluster to 'ondemand' then set the big cluster to
+ # 'performance'.
+ # Note, no non-big.LITTLE boards support cpufreq so this will
+ # have no effect on them.
+ #
+ echo "ondemand" > /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor 2>/dev/null || true
+ echo "ondemand" > /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor 2>/dev/null || true
+ echo "ondemand" > /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor 2>/dev/null || true
+ echo "ondemand" > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor 2>/dev/null || true
+ echo "performance" > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor 2>/dev/null || true
+end script