-
由 K. Y. Srinivasan 提交于
On the interrupt path, we repeatedly establish the pointer to the storvsc_device. While the compiler does inline get_in_stor_device() (and other static functions) in the call chain in the interrupt path, the compiler is repeatedly inlining the call to get_in_stor_device() each time it is invoked. The return value of get_in_stor_device() can be cached in the interrupt path since there is higher level serialization in place to ensure correct handling when the module unload races with the processing of an incoming message from the host. Optimize this code path by caching the pointer to storvsc_device and passing it as an argument. Signed-off-by: NK. Y. Srinivasan <kys@microsoft.com> Reviewed-by: NLong Li <longli@microsoft.com> Reviewed-by: NJohannes Thumshirn <jthumshirn@suse.de> Reviewed-by: NHannes Reinecke <hare@suse.com> Tested-by: NAlex Ng <alexng@microsoft.com> Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
03996f20