Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6

Pull crypto fix from Herbert Xu:
"This push fixes a potential panic in cryptd which may occur with
crypto drivers such as aesni-intel."

* git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6:
crypto: cryptd - disable softirqs in cryptd_queue_worker to prevent data corruption

+8 -3
+8 -3
crypto/cryptd.c
··· 137 137 struct crypto_async_request *req, *backlog; 138 138 139 139 cpu_queue = container_of(work, struct cryptd_cpu_queue, work); 140 - /* Only handle one request at a time to avoid hogging crypto 141 - * workqueue. preempt_disable/enable is used to prevent 142 - * being preempted by cryptd_enqueue_request() */ 140 + /* 141 + * Only handle one request at a time to avoid hogging crypto workqueue. 142 + * preempt_disable/enable is used to prevent being preempted by 143 + * cryptd_enqueue_request(). local_bh_disable/enable is used to prevent 144 + * cryptd_enqueue_request() being accessed from software interrupts. 145 + */ 146 + local_bh_disable(); 143 147 preempt_disable(); 144 148 backlog = crypto_get_backlog(&cpu_queue->queue); 145 149 req = crypto_dequeue_request(&cpu_queue->queue); 146 150 preempt_enable(); 151 + local_bh_enable(); 147 152 148 153 if (!req) 149 154 return;