mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-29 23:53:32 +00:00
kgdb fixes for 5.6-rc1
One of the simplifications added for 5.6-rc1 has caused build regressions on some platforms (it was reported for sparc64). This pull request fixes it with a direct revert. Signed-off-by: Daniel Thompson <daniel.thompson@linaro.org> -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEELzVBU1D3lWq6cKzwfOMlXTn3iKEFAl48JNUACgkQfOMlXTn3 iKF7cA/9G3hl4IB1D2OfbbLb6lXPu+TEWDsQk7Y5CmKgbclMv+JL684TJCU7rnFB Xxjho97Cj9bqR3ZGDInxLcJrAnbaD6756UC7k5jVUIcdFFhprjdgWImyJVs6VXoe ESahpSna+Ap3ZsMBgQJUfnBbDzY/B3jmPQ8/f7qOIjBb17AdarisClk2CdbY90Gi 0dfJti65SLqE10on7Clx+9HmNkPp9Rs+1+4O9r2LW5c9b6aNop8iQPdLdl7/B2Me V9Vs5uAsLqNKBpyFuq3PG1AXzK53gK2N3wZqmOPAuKAObDM/wUqvVHaAJHqiIWN9 U+Dn9aZCIW3Mbeat4RijVT8CCoz1WEvCQM1MUk5sbgBnQ90vwSyDmJrA88GMoHtI wmP5OJL/EdghGWG9+PcFH2+axD87iEq48hxVXlB9UTtvoyjLkkiXm3WvOx2UC8rX 8tjEZvivMO3GeJBxYQUXvSFzGUeJAMZhMQm9+0qaw//SJK5GyEG0CfDDp5Ts1q2w +F689/TaygpOZGP5m1iFqhNAoR03g+NTX33/CYoa+Yplnn+j+LU4ZTlNq4vl1VY6 lATR3Eu/vLYhCqdeXaZpRx4cthEFQ3kl8tT53RU2Ip20cNQkNooHPpCpkk0vSuGx X0PV9CX/nAFWGrfbJLCW3AQ2ZTxqdl8i2Q7HzOJUJPrddppqN/U= =Pb+W -----END PGP SIGNATURE----- Merge tag 'kgdb-fixes-5.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/danielt/linux Pull kgdb fix from Daniel Thompson: "One of the simplifications added for 5.6-rc1 has caused build regressions on some platforms (it was reported for sparc64). This fixes it with a revert" * tag 'kgdb-fixes-5.6-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/danielt/linux: Revert "kdb: Get rid of confusing diag msg from "rd" if current task has no regs"
This commit is contained in:
commit
d854b2d639
1 changed files with 15 additions and 13 deletions
|
@ -543,8 +543,9 @@ int kdbgetaddrarg(int argc, const char **argv, int *nextarg,
|
||||||
if (diag)
|
if (diag)
|
||||||
return diag;
|
return diag;
|
||||||
} else if (symname[0] == '%') {
|
} else if (symname[0] == '%') {
|
||||||
if (kdb_check_regs())
|
diag = kdb_check_regs();
|
||||||
return 0;
|
if (diag)
|
||||||
|
return diag;
|
||||||
/* Implement register values with % at a later time as it is
|
/* Implement register values with % at a later time as it is
|
||||||
* arch optional.
|
* arch optional.
|
||||||
*/
|
*/
|
||||||
|
@ -1835,7 +1836,8 @@ static int kdb_go(int argc, const char **argv)
|
||||||
*/
|
*/
|
||||||
static int kdb_rd(int argc, const char **argv)
|
static int kdb_rd(int argc, const char **argv)
|
||||||
{
|
{
|
||||||
int len = 0;
|
int len = kdb_check_regs();
|
||||||
|
#if DBG_MAX_REG_NUM > 0
|
||||||
int i;
|
int i;
|
||||||
char *rname;
|
char *rname;
|
||||||
int rsize;
|
int rsize;
|
||||||
|
@ -1844,14 +1846,8 @@ static int kdb_rd(int argc, const char **argv)
|
||||||
u16 reg16;
|
u16 reg16;
|
||||||
u8 reg8;
|
u8 reg8;
|
||||||
|
|
||||||
if (kdb_check_regs())
|
if (len)
|
||||||
return 0;
|
return len;
|
||||||
|
|
||||||
/* Fallback to Linux showregs() if we don't have DBG_MAX_REG_NUM */
|
|
||||||
if (DBG_MAX_REG_NUM <= 0) {
|
|
||||||
kdb_dumpregs(kdb_current_regs);
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
for (i = 0; i < DBG_MAX_REG_NUM; i++) {
|
for (i = 0; i < DBG_MAX_REG_NUM; i++) {
|
||||||
rsize = dbg_reg_def[i].size * 2;
|
rsize = dbg_reg_def[i].size * 2;
|
||||||
|
@ -1893,7 +1889,12 @@ static int kdb_rd(int argc, const char **argv)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
kdb_printf("\n");
|
kdb_printf("\n");
|
||||||
|
#else
|
||||||
|
if (len)
|
||||||
|
return len;
|
||||||
|
|
||||||
|
kdb_dumpregs(kdb_current_regs);
|
||||||
|
#endif
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1927,8 +1928,9 @@ static int kdb_rm(int argc, const char **argv)
|
||||||
if (diag)
|
if (diag)
|
||||||
return diag;
|
return diag;
|
||||||
|
|
||||||
if (kdb_check_regs())
|
diag = kdb_check_regs();
|
||||||
return 0;
|
if (diag)
|
||||||
|
return diag;
|
||||||
|
|
||||||
diag = KDB_BADREG;
|
diag = KDB_BADREG;
|
||||||
for (i = 0; i < DBG_MAX_REG_NUM; i++) {
|
for (i = 0; i < DBG_MAX_REG_NUM; i++) {
|
||||||
|
|
Loading…
Reference in a new issue