<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git, branch Colibri_T30_LinuxImageV2.3Beta1_20140804</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>Revert "fbcon: workaround full screen custom boot logo issue and disable cursor"</title>
<updated>2014-08-04T11:08:05+00:00</updated>
<author>
<name>Marcel Ziswiler</name>
<email>marcel.ziswiler@toradex.com</email>
</author>
<published>2014-08-04T11:08:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=5df112cd75b9cf85a5a976f847bdcba4020c2dcd'/>
<id>5df112cd75b9cf85a5a976f847bdcba4020c2dcd</id>
<content type='text'>
The whole rounding stuff really depends on a specific resolution.

This reverts commit 4dd83942b418b937e3da02746baabf63f37fe682.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The whole rounding stuff really depends on a specific resolution.

This reverts commit 4dd83942b418b937e3da02746baabf63f37fe682.
</pre>
</div>
</content>
</entry>
<entry>
<title>fbcon: workaround full screen custom boot logo issue and disable cursor</title>
<updated>2014-08-04T09:28:48+00:00</updated>
<author>
<name>Raul Munoz</name>
<email>raul.munoz@toradex.com</email>
</author>
<published>2014-08-04T09:28:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=4dd83942b418b937e3da02746baabf63f37fe682'/>
<id>4dd83942b418b937e3da02746baabf63f37fe682</id>
<content type='text'>
Force round down in division calculating required logo height as
preceding code did round up as follows:

logo_lines = DIV_ROUND_UP(logo_height, vc-&gt;vc_font.height);

Which resulted in no boot-logo shown at all due to not enough lines
being available.

Additionally disable cursor for custom boot logo.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Force round down in division calculating required logo height as
preceding code did round up as follows:

logo_lines = DIV_ROUND_UP(logo_height, vc-&gt;vc_font.height);

Which resulted in no boot-logo shown at all due to not enough lines
being available.

Additionally disable cursor for custom boot logo.
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "fbcon: workaround full screen boot-logo issue"</title>
<updated>2014-08-04T07:58:47+00:00</updated>
<author>
<name>Marcel Ziswiler</name>
<email>marcel.ziswiler@toradex.com</email>
</author>
<published>2014-08-04T07:58:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=2f6ab2173097420f32bf5bf7f18efa4725b3246d'/>
<id>2f6ab2173097420f32bf5bf7f18efa4725b3246d</id>
<content type='text'>
Using this unconditionally cuts the birds feet (;-p).

This reverts commit 491f263ebfb338c59abfbde6d4e0e7256a0150fa.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Using this unconditionally cuts the birds feet (;-p).

This reverts commit 491f263ebfb338c59abfbde6d4e0e7256a0150fa.
</pre>
</div>
</content>
</entry>
<entry>
<title>ARM: 7670/1: fix the memset fix</title>
<updated>2014-07-28T16:19:49+00:00</updated>
<author>
<name>Nicolas Pitre</name>
<email>nicolas.pitre@linaro.org</email>
</author>
<published>2013-03-12T12:00:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=b2ec16b357ec3c965883737a3176fcf64e8a00d2'/>
<id>b2ec16b357ec3c965883737a3176fcf64e8a00d2</id>
<content type='text'>
Commit 455bd4c430b0 ("ARM: 7668/1: fix memset-related crashes caused by
recent GCC (4.7.2) optimizations") attempted to fix a compliance issue
with the memset return value.  However the memset itself became broken
by that patch for misaligned pointers.

This fixes the above by branching over the entry code from the
misaligned fixup code to avoid reloading the original pointer.

Also, because the function entry alignment is wrong in the Thumb mode
compilation, that fixup code is moved to the end.

While at it, the entry instructions are slightly reworked to help dual
issue pipelines.

Signed-off-by: Nicolas Pitre &lt;nico@linaro.org&gt;
Tested-by: Alexander Holler &lt;holler@ahsoftware.de&gt;
Signed-off-by: Russell King &lt;rmk+kernel@arm.linux.org.uk&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Commit 455bd4c430b0 ("ARM: 7668/1: fix memset-related crashes caused by
recent GCC (4.7.2) optimizations") attempted to fix a compliance issue
with the memset return value.  However the memset itself became broken
by that patch for misaligned pointers.

This fixes the above by branching over the entry code from the
misaligned fixup code to avoid reloading the original pointer.

Also, because the function entry alignment is wrong in the Thumb mode
compilation, that fixup code is moved to the end.

While at it, the entry instructions are slightly reworked to help dual
issue pipelines.

Signed-off-by: Nicolas Pitre &lt;nico@linaro.org&gt;
Tested-by: Alexander Holler &lt;holler@ahsoftware.de&gt;
Signed-off-by: Russell King &lt;rmk+kernel@arm.linux.org.uk&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ARM: 7668/1: fix memset-related crashes caused by recent GCC (4.7.2) optimizations</title>
<updated>2014-07-28T16:19:09+00:00</updated>
<author>
<name>Ivan Djelic</name>
<email>ivan.djelic@parrot.com</email>
</author>
<published>2013-03-06T19:09:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=c0fe2323296a99c0ad051e36d35de822fe948587'/>
<id>c0fe2323296a99c0ad051e36d35de822fe948587</id>
<content type='text'>
Recent GCC versions (e.g. GCC-4.7.2) perform optimizations based on
assumptions about the implementation of memset and similar functions.
The current ARM optimized memset code does not return the value of
its first argument, as is usually expected from standard implementations.

For instance in the following function:

void debug_mutex_lock_common(struct mutex *lock, struct mutex_waiter *waiter)
{
	memset(waiter, MUTEX_DEBUG_INIT, sizeof(*waiter));
	waiter-&gt;magic = waiter;
	INIT_LIST_HEAD(&amp;waiter-&gt;list);
}

compiled as:

800554d0 &lt;debug_mutex_lock_common&gt;:
800554d0:       e92d4008        push    {r3, lr}
800554d4:       e1a00001        mov     r0, r1
800554d8:       e3a02010        mov     r2, #16 ; 0x10
800554dc:       e3a01011        mov     r1, #17 ; 0x11
800554e0:       eb04426e        bl      80165ea0 &lt;memset&gt;
800554e4:       e1a03000        mov     r3, r0
800554e8:       e583000c        str     r0, [r3, #12]
800554ec:       e5830000        str     r0, [r3]
800554f0:       e5830004        str     r0, [r3, #4]
800554f4:       e8bd8008        pop     {r3, pc}

GCC assumes memset returns the value of pointer 'waiter' in register r0; causing
register/memory corruptions.

This patch fixes the return value of the assembly version of memset.
It adds a 'mov' instruction and merges an additional load+store into
existing load/store instructions.
For ease of review, here is a breakdown of the patch into 4 simple steps:

Step 1
======
Perform the following substitutions:
ip -&gt; r8, then
r0 -&gt; ip,
and insert 'mov ip, r0' as the first statement of the function.
At this point, we have a memset() implementation returning the proper result,
but corrupting r8 on some paths (the ones that were using ip).

Step 2
======
Make sure r8 is saved and restored when (! CALGN(1)+0) == 1:

save r8:
-       str     lr, [sp, #-4]!
+       stmfd   sp!, {r8, lr}

and restore r8 on both exit paths:
-       ldmeqfd sp!, {pc}               @ Now &lt;64 bytes to go.
+       ldmeqfd sp!, {r8, pc}           @ Now &lt;64 bytes to go.
(...)
        tst     r2, #16
        stmneia ip!, {r1, r3, r8, lr}
-       ldr     lr, [sp], #4
+       ldmfd   sp!, {r8, lr}

Step 3
======
Make sure r8 is saved and restored when (! CALGN(1)+0) == 0:

save r8:
-       stmfd   sp!, {r4-r7, lr}
+       stmfd   sp!, {r4-r8, lr}

and restore r8 on both exit paths:
        bgt     3b
-       ldmeqfd sp!, {r4-r7, pc}
+       ldmeqfd sp!, {r4-r8, pc}
(...)
        tst     r2, #16
        stmneia ip!, {r4-r7}
-       ldmfd   sp!, {r4-r7, lr}
+       ldmfd   sp!, {r4-r8, lr}

Step 4
======
Rewrite register list "r4-r7, r8" as "r4-r8".

Signed-off-by: Ivan Djelic &lt;ivan.djelic@parrot.com&gt;
Reviewed-by: Nicolas Pitre &lt;nico@linaro.org&gt;
Signed-off-by: Dirk Behme &lt;dirk.behme@gmail.com&gt;
Signed-off-by: Russell King &lt;rmk+kernel@arm.linux.org.uk&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Recent GCC versions (e.g. GCC-4.7.2) perform optimizations based on
assumptions about the implementation of memset and similar functions.
The current ARM optimized memset code does not return the value of
its first argument, as is usually expected from standard implementations.

For instance in the following function:

void debug_mutex_lock_common(struct mutex *lock, struct mutex_waiter *waiter)
{
	memset(waiter, MUTEX_DEBUG_INIT, sizeof(*waiter));
	waiter-&gt;magic = waiter;
	INIT_LIST_HEAD(&amp;waiter-&gt;list);
}

compiled as:

800554d0 &lt;debug_mutex_lock_common&gt;:
800554d0:       e92d4008        push    {r3, lr}
800554d4:       e1a00001        mov     r0, r1
800554d8:       e3a02010        mov     r2, #16 ; 0x10
800554dc:       e3a01011        mov     r1, #17 ; 0x11
800554e0:       eb04426e        bl      80165ea0 &lt;memset&gt;
800554e4:       e1a03000        mov     r3, r0
800554e8:       e583000c        str     r0, [r3, #12]
800554ec:       e5830000        str     r0, [r3]
800554f0:       e5830004        str     r0, [r3, #4]
800554f4:       e8bd8008        pop     {r3, pc}

GCC assumes memset returns the value of pointer 'waiter' in register r0; causing
register/memory corruptions.

This patch fixes the return value of the assembly version of memset.
It adds a 'mov' instruction and merges an additional load+store into
existing load/store instructions.
For ease of review, here is a breakdown of the patch into 4 simple steps:

Step 1
======
Perform the following substitutions:
ip -&gt; r8, then
r0 -&gt; ip,
and insert 'mov ip, r0' as the first statement of the function.
At this point, we have a memset() implementation returning the proper result,
but corrupting r8 on some paths (the ones that were using ip).

Step 2
======
Make sure r8 is saved and restored when (! CALGN(1)+0) == 1:

save r8:
-       str     lr, [sp, #-4]!
+       stmfd   sp!, {r8, lr}

and restore r8 on both exit paths:
-       ldmeqfd sp!, {pc}               @ Now &lt;64 bytes to go.
+       ldmeqfd sp!, {r8, pc}           @ Now &lt;64 bytes to go.
(...)
        tst     r2, #16
        stmneia ip!, {r1, r3, r8, lr}
-       ldr     lr, [sp], #4
+       ldmfd   sp!, {r8, lr}

Step 3
======
Make sure r8 is saved and restored when (! CALGN(1)+0) == 0:

save r8:
-       stmfd   sp!, {r4-r7, lr}
+       stmfd   sp!, {r4-r8, lr}

and restore r8 on both exit paths:
        bgt     3b
-       ldmeqfd sp!, {r4-r7, pc}
+       ldmeqfd sp!, {r4-r8, pc}
(...)
        tst     r2, #16
        stmneia ip!, {r4-r7}
-       ldmfd   sp!, {r4-r7, lr}
+       ldmfd   sp!, {r4-r8, lr}

Step 4
======
Rewrite register list "r4-r7, r8" as "r4-r8".

Signed-off-by: Ivan Djelic &lt;ivan.djelic@parrot.com&gt;
Reviewed-by: Nicolas Pitre &lt;nico@linaro.org&gt;
Signed-off-by: Dirk Behme &lt;dirk.behme@gmail.com&gt;
Signed-off-by: Russell King &lt;rmk+kernel@arm.linux.org.uk&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>apalis/colibri t20/t30: enable vlan functionality</title>
<updated>2014-07-26T00:21:10+00:00</updated>
<author>
<name>Marcel Ziswiler</name>
<email>marcel.ziswiler@toradex.com</email>
</author>
<published>2014-07-26T00:21:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=f624a2114bf6f065f6836aa6da1a14291af2445b'/>
<id>f624a2114bf6f065f6836aa6da1a14291af2445b</id>
<content type='text'>
Enable VLAN networking functionality.

While at it also enable some more kernel modules for Apalis T30 PCIe
based devices like the Intel E1000E NICs, Intel IWLAGN Wi-Fi cards,
PCIe serial cards and XHCI based USB 3.0 controllers.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Enable VLAN networking functionality.

While at it also enable some more kernel modules for Apalis T30 PCIe
based devices like the Intel E1000E NICs, Intel IWLAGN Wi-Fi cards,
PCIe serial cards and XHCI based USB 3.0 controllers.
</pre>
</div>
</content>
</entry>
<entry>
<title>Revert "asoc: tegra20_ac97: fix sampling rate"</title>
<updated>2014-07-25T23:49:01+00:00</updated>
<author>
<name>Marcel Ziswiler</name>
<email>marcel.ziswiler@toradex.com</email>
</author>
<published>2014-07-25T23:39:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=fadac2035f5f0fb0e03f1122bcf334cc24b898ce'/>
<id>fadac2035f5f0fb0e03f1122bcf334cc24b898ce</id>
<content type='text'>
This reverts commit f162e88fc6aac0fef03c49c1ac596995a03ff134.

Somehow NVIDIA's media player does not like it to be fixed as
it starts stuttering like crazy at times.

Still keep the dangerous time out handling clean-up.

While at it get rid of the excessive dev_info() logging as well.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This reverts commit f162e88fc6aac0fef03c49c1ac596995a03ff134.

Somehow NVIDIA's media player does not like it to be fixed as
it starts stuttering like crazy at times.

Still keep the dangerous time out handling clean-up.

While at it get rid of the excessive dev_info() logging as well.
</pre>
</div>
</content>
</entry>
<entry>
<title>cgroup: remove synchronize_rcu() from cgroup_attach_{task|proc}()</title>
<updated>2014-07-25T20:31:06+00:00</updated>
<author>
<name>Li Zefan</name>
<email>lizefan@huawei.com</email>
</author>
<published>2013-01-14T09:23:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=bfcf5eebc04870bac5dbeaa923e6cce14266a1de'/>
<id>bfcf5eebc04870bac5dbeaa923e6cce14266a1de</id>
<content type='text'>
These 2 syncronize_rcu()s make attaching a task to a cgroup
quite slow, and it can't be ignored in some situations.

A real case from Colin Cross: Android uses cgroups heavily to
manage thread priorities, putting threads in a background group
with reduced cpu.shares when they are not visible to the user,
and in a foreground group when they are. Some RPCs from foreground
threads to background threads will temporarily move the background
thread into the foreground group for the duration of the RPC.
This results in many calls to cgroup_attach_task.

In cgroup_attach_task() it's task-&gt;cgroups that is protected by RCU,
and put_css_set() calls kfree_rcu() to free it.

If we remove this synchronize_rcu(), there can be threads in RCU-read
sections accessing their old cgroup via current-&gt;cgroups with
concurrent rmdir operation, but this is safe.

 # time for ((i=0; i&lt;50; i++)) { echo $$ &gt; /mnt/sub/tasks; echo $$ &gt; /mnt/tasks; }

real    0m2.524s
user    0m0.008s
sys     0m0.004s

With this patch:

real    0m0.004s
user    0m0.004s
sys     0m0.000s

tj: These synchronize_rcu()s are utterly confused.  synchornize_rcu()
    necessarily has to come between two operations to guarantee that
    the changes made by the former operation are visible to all rcu
    readers before proceeding to the latter operation.  Here,
    synchornize_rcu() are at the end of attach operations with nothing
    beyond it.  Its only effect would be delaying completion of
    write(2) to sysfs tasks/procs files until all rcu readers see the
    change, which doesn't mean anything.

Signed-off-by: Li Zefan &lt;lizefan@huawei.com&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Reported-by: Colin Cross &lt;ccross@google.com&gt;

Conflicts:
	kernel/cgroup.c
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
These 2 syncronize_rcu()s make attaching a task to a cgroup
quite slow, and it can't be ignored in some situations.

A real case from Colin Cross: Android uses cgroups heavily to
manage thread priorities, putting threads in a background group
with reduced cpu.shares when they are not visible to the user,
and in a foreground group when they are. Some RPCs from foreground
threads to background threads will temporarily move the background
thread into the foreground group for the duration of the RPC.
This results in many calls to cgroup_attach_task.

In cgroup_attach_task() it's task-&gt;cgroups that is protected by RCU,
and put_css_set() calls kfree_rcu() to free it.

If we remove this synchronize_rcu(), there can be threads in RCU-read
sections accessing their old cgroup via current-&gt;cgroups with
concurrent rmdir operation, but this is safe.

 # time for ((i=0; i&lt;50; i++)) { echo $$ &gt; /mnt/sub/tasks; echo $$ &gt; /mnt/tasks; }

real    0m2.524s
user    0m0.008s
sys     0m0.004s

With this patch:

real    0m0.004s
user    0m0.004s
sys     0m0.000s

tj: These synchronize_rcu()s are utterly confused.  synchornize_rcu()
    necessarily has to come between two operations to guarantee that
    the changes made by the former operation are visible to all rcu
    readers before proceeding to the latter operation.  Here,
    synchornize_rcu() are at the end of attach operations with nothing
    beyond it.  Its only effect would be delaying completion of
    write(2) to sysfs tasks/procs files until all rcu readers see the
    change, which doesn't mean anything.

Signed-off-by: Li Zefan &lt;lizefan@huawei.com&gt;
Signed-off-by: Tejun Heo &lt;tj@kernel.org&gt;
Reported-by: Colin Cross &lt;ccross@google.com&gt;

Conflicts:
	kernel/cgroup.c
</pre>
</div>
</content>
</entry>
<entry>
<title>apalis/colibri t30: use hda hdmi audio and split sound init</title>
<updated>2014-07-25T19:53:00+00:00</updated>
<author>
<name>Marcel Ziswiler</name>
<email>marcel.ziswiler@toradex.com</email>
</author>
<published>2014-07-25T19:53:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=0ef8a43b078dc63d2f1bf69c9d6ee480bdcbb6e7'/>
<id>0ef8a43b078dc63d2f1bf69c9d6ee480bdcbb6e7</id>
<content type='text'>
Use HDA HDMI audio now on Colibri T30 as well allowing for up to 7.1
multi-channel playback. Split board sound initialisation between Apalis
and Colibri T30 in order to distinguish better between default SPDIF
being supported out-of-the-box on Apalis vs. this being an optional
feature for the Colibri. Therefore remove SPDIF for the Colibri T30.

While at it add csus clock required for vi_sensor camera master clock
on Apalis T30 and clk_out_2/extern2 for Colibri T30, fix debug UART1
initialisation, get rid of spurious CONFIG_SND_USB enable and further
clean-up both board platform data files.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use HDA HDMI audio now on Colibri T30 as well allowing for up to 7.1
multi-channel playback. Split board sound initialisation between Apalis
and Colibri T30 in order to distinguish better between default SPDIF
being supported out-of-the-box on Apalis vs. this being an optional
feature for the Colibri. Therefore remove SPDIF for the Colibri T30.

While at it add csus clock required for vi_sensor camera master clock
on Apalis T30 and clk_out_2/extern2 for Colibri T30, fix debug UART1
initialisation, get rid of spurious CONFIG_SND_USB enable and further
clean-up both board platform data files.
</pre>
</div>
</content>
</entry>
<entry>
<title>apalis/colibri t30: make hda 2nd sound card hack</title>
<updated>2014-07-25T09:41:45+00:00</updated>
<author>
<name>Marcel Ziswiler</name>
<email>marcel.ziswiler@toradex.com</email>
</author>
<published>2014-07-25T09:41:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=fff75b252e0aed1d8be2b62234624f726c153776'/>
<id>fff75b252e0aed1d8be2b62234624f726c153776</id>
<content type='text'>
Hack HDA driver to make it the 2nd rather than the first sound card as
the first one should be the SGTL5000 which is always present on our T30
modules. Especially on Ixora where there is no HDA codec on the carrier
board HDA being the first sound card does not make much sense even more
though as there was no primary device (e.g. device=hw:0,0).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Hack HDA driver to make it the 2nd rather than the first sound card as
the first one should be the SGTL5000 which is always present on our T30
modules. Especially on Ixora where there is no HDA codec on the carrier
board HDA being the first sound card does not make much sense even more
though as there was no primary device (e.g. device=hw:0,0).
</pre>
</div>
</content>
</entry>
</feed>
