// SPDX-License-Identifier: GPL-2.0 /* * Precise Delay Loops for SuperH * * Copyright (C) 1999 Niibe Yutaka & Kaz Kojima */ #include <linux/sched.h> #include <linux/delay.h>
void __delay(unsigned long loops) { __asm__ __volatile__( /* * ST40-300 appears to have an issue with this code, * normally taking two cycles each loop, as with all * other SH variants. If however the branch and the * delay slot straddle an 8 byte boundary, this increases * to 3 cycles. * This align directive ensures this doesn't occur. */ ".balign 8\n\t" "tst %0, %0\n\t" "1:\t" "bf/s 1b\n\t" " dt %0" : "=r" (loops) : "0" (loops) : "t"); }Contributors
Person | Tokens | Prop | Commits | CommitProp |
Linus Torvalds (pre-git) | 11 | 78.57% | 1 | 50.00% |
Stuart Menefy | 3 | 21.43% | 1 | 50.00% |
Total | 14 | 100.00% | 2 | 100.00% |
Person | Tokens | Prop | Commits | CommitProp |
Linus Torvalds (pre-git) | 15 | 71.43% | 1 | 50.00% |
Stuart Menefy | 6 | 28.57% | 1 | 50.00% |
Total | 21 | 100.00% | 2 | 100.00% |
Person | Tokens | Prop | Commits | CommitProp |
Linus Torvalds (pre-git) | 17 | 100.00% | 2 | 100.00% |
Total | 17 | 100.00% | 2 | 100.00% |
Person | Tokens | Prop | Commits | CommitProp |
Andrew Morton | 16 | 100.00% | 1 | 100.00% |
Total | 16 | 100.00% | 1 | 100.00% |
Person | Tokens | Prop | Commits | CommitProp |
Linus Torvalds (pre-git) | 50 | 65.79% | 2 | 33.33% |
Andrew Morton | 16 | 21.05% | 1 | 16.67% |
Stuart Menefy | 9 | 11.84% | 2 | 33.33% |
Greg Kroah-Hartman | 1 | 1.32% | 1 | 16.67% |
Total | 76 | 100.00% | 6 | 100.00% |