Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset 712c4ba in mainline for kernel/generic/src/synch/spinlock.c


Ignore:
Timestamp:
2011-05-20T16:09:24Z (11 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master
Children:
b6f3e7e
Parents:
326bf65
Message:

avoid spinlocks to be taken in the direct code path to physically outputing kconsole characters to the framebuffer (this fixes ticket #243)
the spinlock in printf() (kernel) was sacrificed, this might lead potentially to scrambled kconsole output
the hack of ignoring spinlocks whose names start with "*" in the livelock detector can be removed

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/synch/spinlock.c

    r326bf65 r712c4ba  
    8484                 * This conserns especially printf_lock and the
    8585                 * framebuffer lock.
    86                  *
    87                  * Any lock whose name is prefixed by "*" will be
    88                  * ignored by this deadlock detection routine
    89                  * as this might cause an infinite recursion.
    90                  * We trust our code that there is no possible deadlock
    91                  * caused by these locks (except when an exception
    92                  * is triggered for instance by printf()).
    93                  *
    94                  * We encountered false positives caused by very
    95                  * slow framebuffer interaction (especially when
    96                  * run in a simulator) that caused problems with both
    97                  * printf_lock and the framebuffer lock.
    98                  *
    9986                 */
    100                 if (lock->name[0] == '*')
    101                         continue;
    102                
    10387                if (i++ > DEADLOCK_THRESHOLD) {
    10488                        printf("cpu%u: looping on spinlock %p:%s, "
Note: See TracChangeset for help on using the changeset viewer.