History

objtool: Fix error handling for STD/CLD warnings

Actually return an error (and display a backtrace, if requested) for directional bit warnings.

Josh Poimboeuf committed 5 years ago

Commit 6f567c91 parent c9c324d1 file · +6 −2Browse files

Unified · Split

tools/objtool/check.c+6−2
@@ -2651,15 +2651,19 @@ static int validate_branch(struct objtool_file *file, struct symbol *func, · 2650 unmodified lines
2651 break;2651 break;
2652 2652
2653 case INSN_STD:2653 case INSN_STD:
2654 if (state.df)2654 if (state.df) {
2655 WARN_FUNC("recursive STD", sec, insn->offset);2655 WARN_FUNC("recursive STD", sec, insn->offset);
2656 return 1;
2657 }
2656 2658
2657 state.df = true;2659 state.df = true;
2658 break;2660 break;
2659 2661
2660 case INSN_CLD:2662 case INSN_CLD:
2661 if (!state.df && func)2663 if (!state.df && func) {
2662 WARN_FUNC("redundant CLD", sec, insn->offset);2664 WARN_FUNC("redundant CLD", sec, insn->offset);
2665 return 1;
2666 }
2663 2667
2664 state.df = false;2668 state.df = false;
2665 break;2669 break;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t