diff options
| author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-07-27 11:12:39 -0700 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-07-27 11:12:39 -0700 |
| commit | 92311e46ecf2298d87f175c8449ab4d8c400a38e (patch) | |
| tree | 92bfbbc23c3acfb035a88bf257849465b26aa156 /kernel/resource.c | |
| parent | d684779335856d8177514b42a801d46088d897b0 (diff) | |
| parent | cbfe8fa6cd672011c755c3cd85c9ffd4e2d10a6f (diff) | |
Merge 4.2-rc4 into tty-next
Other serial driver work wants to build on patches now in 4.2-rc4 so
merge the branch so this can properly happen.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'kernel/resource.c')
| -rw-r--r-- | kernel/resource.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/kernel/resource.c b/kernel/resource.c index 90552aab5f2d..fed052a1bc9f 100644 --- a/kernel/resource.c +++ b/kernel/resource.c @@ -504,13 +504,13 @@ int region_is_ram(resource_size_t start, unsigned long size) { struct resource *p; resource_size_t end = start + size - 1; - int flags = IORESOURCE_MEM | IORESOURCE_BUSY; + unsigned long flags = IORESOURCE_MEM | IORESOURCE_BUSY; const char *name = "System RAM"; int ret = -1; read_lock(&resource_lock); for (p = iomem_resource.child; p ; p = p->sibling) { - if (end < p->start) + if (p->end < start) continue; if (p->start <= start && end <= p->end) { @@ -521,7 +521,7 @@ int region_is_ram(resource_size_t start, unsigned long size) ret = 1; break; } - if (p->end < start) + if (end < p->start) break; /* not found */ } read_unlock(&resource_lock); |
