History

lockdep: Move list.h inclusion into lockdep.h

Currently lockdep_types.h includes list.h without actually using any of its macros or functions. All it needs are the type definitions which were moved into types.h long ago. This potentially causes inclusion loops because both are included by many core header files. This patch moves the list.h inclusion into lockdep.h. Note that we could probably remove it completely but that could potentially result in compile failures should any end users not include list.h directly and also be unlucky enough to not get list.h via some other header file.

Herbert Xu committed 6 years ago

Commit 5be542e1 parent f9ad4a52 files · +1 −2Browse files

Showing the changes to include/linux (2 of 2 files). Show all

Unified · Split

2 files
  1. include/linux/lockdep.h +1 −0
  2. include/linux/lockdep_types.h +0 −2
include/linux/lockdep.h+1−0
@@ -22,6 +22,7 @@ extern int lock_stat; · 21 unmodified lines
22#ifdef CONFIG_LOCKDEP22#ifdef CONFIG_LOCKDEP
23 23
24#include <linux/linkage.h>24#include <linux/linkage.h>
25#include <linux/list.h>
25#include <linux/debug_locks.h>26#include <linux/debug_locks.h>
26#include <linux/stacktrace.h>27#include <linux/stacktrace.h>
27 28
include/linux/lockdep_types.h+0−2
@@ -32,8 +32,6 @@ enum lockdep_wait_type { · 31 unmodified lines
32 32
33#ifdef CONFIG_LOCKDEP33#ifdef CONFIG_LOCKDEP
34 34
35#include <linux/list.h>
36
37/*35/*
38 * We'd rather not expose kernel/lockdep_states.h this wide, but we do need36 * We'd rather not expose kernel/lockdep_states.h this wide, but we do need
39 * the total number of states... :-(37 * the total number of states... :-(

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