mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-14 08:36:12 -04:00
Linux 3.19-rc7
-----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAABAgAGBQJUzvgKAAoJEHm+PkMAQRiG8XQH/1qVbHI4pP0KcnzfZUHq/mXq RuS4aJMwLm/Y6cXFraXBDaPde1A3CPtwtpob2C6giKcfu2zXGunY65haOEeJWNpX lCbBsLkNC3oDNkygBpVr5Zd6yibaw63WBjjLnpAi7pn2G2Zm2zB8DfILWWWMb7yz MH8ZXV+/xIYCTkjNWGWA1iMjmdYqu0PQHPeOgLsYQ+u7rxfM1zb/wHEkjqUZS6iu IaaZv7PV2PnFYnqib/iIPYjAEDvSQ4vN/7b82zlFd2Culm9j/568KCCWUPhJTb2l X0u4QYs49GnMTWVRa3bgYxS/nTUaE/6DeWs2y2WzqTt0/XDntVUnok0blUeDxGk= =o2kS -----END PGP SIGNATURE----- Merge tag 'v3.19-rc7' into perf/core, to merge fixes before applying new changes Signed-off-by: Ingo Molnar <mingo@kernel.org>
This commit is contained in:
commit
8f4bf4bcc4
206 changed files with 2194 additions and 1190 deletions
|
|
@ -150,7 +150,7 @@ static int map_lookup_elem(union bpf_attr *attr)
|
|||
int ufd = attr->map_fd;
|
||||
struct fd f = fdget(ufd);
|
||||
struct bpf_map *map;
|
||||
void *key, *value;
|
||||
void *key, *value, *ptr;
|
||||
int err;
|
||||
|
||||
if (CHECK_ATTR(BPF_MAP_LOOKUP_ELEM))
|
||||
|
|
@ -169,20 +169,29 @@ static int map_lookup_elem(union bpf_attr *attr)
|
|||
if (copy_from_user(key, ukey, map->key_size) != 0)
|
||||
goto free_key;
|
||||
|
||||
err = -ENOENT;
|
||||
rcu_read_lock();
|
||||
value = map->ops->map_lookup_elem(map, key);
|
||||
err = -ENOMEM;
|
||||
value = kmalloc(map->value_size, GFP_USER);
|
||||
if (!value)
|
||||
goto err_unlock;
|
||||
goto free_key;
|
||||
|
||||
rcu_read_lock();
|
||||
ptr = map->ops->map_lookup_elem(map, key);
|
||||
if (ptr)
|
||||
memcpy(value, ptr, map->value_size);
|
||||
rcu_read_unlock();
|
||||
|
||||
err = -ENOENT;
|
||||
if (!ptr)
|
||||
goto free_value;
|
||||
|
||||
err = -EFAULT;
|
||||
if (copy_to_user(uvalue, value, map->value_size) != 0)
|
||||
goto err_unlock;
|
||||
goto free_value;
|
||||
|
||||
err = 0;
|
||||
|
||||
err_unlock:
|
||||
rcu_read_unlock();
|
||||
free_value:
|
||||
kfree(value);
|
||||
free_key:
|
||||
kfree(key);
|
||||
err_put:
|
||||
|
|
|
|||
|
|
@ -7292,13 +7292,12 @@ void __might_sleep(const char *file, int line, int preempt_offset)
|
|||
* since we will exit with TASK_RUNNING make sure we enter with it,
|
||||
* otherwise we will destroy state.
|
||||
*/
|
||||
if (WARN_ONCE(current->state != TASK_RUNNING,
|
||||
WARN_ONCE(current->state != TASK_RUNNING && current->task_state_change,
|
||||
"do not call blocking ops when !TASK_RUNNING; "
|
||||
"state=%lx set at [<%p>] %pS\n",
|
||||
current->state,
|
||||
(void *)current->task_state_change,
|
||||
(void *)current->task_state_change))
|
||||
__set_current_state(TASK_RUNNING);
|
||||
(void *)current->task_state_change);
|
||||
|
||||
___might_sleep(file, line, preempt_offset);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue