lkml.org 
[lkml]   [2019]   [Feb]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRE: [PATCH v2 2/2] Drivers: hv: vmbus: Return -EINVAL if monitor_allocated not set
    Date
    From: Kimberly Brown <kimbrownkd@gmail.com>  Sent: Monday, February 18, 2019 9:38 PM
    >
    > There are two methods for signaling the host: the monitor page mechanism
    > and hypercalls. The monitor page mechanism is used by performance
    > critical channels (storage, networking, etc.) because it provides
    > improved throughput. However, latency is increased. Monitor pages are
    > allocated to these channels.
    >
    > Monitor pages are not allocated to channels that do not use the monitor
    > page mechanism. Therefore, these channels do not have a valid monitor id
    > or valid monitor page data. In these cases, some of the "_show"
    > functions return incorrect data. They return an invalid monitor id and
    > data that is beyond the bounds of the hv_monitor_page array fields.
    >
    > The "channel->offermsg.monitor_allocated" value can be used to determine
    > whether monitor pages have been allocated to a channel. In the affected
    > "_show" functions, verify that "channel->offermsg.monitor_allocated" is
    > set before accessing the monitor id or the monitor page data. If
    > "channel->offermsg.monitor_allocated" is not set, return -EINVAL.
    >
    > Signed-off-by: Kimberly Brown <kimbrownkd@gmail.com>
    >

    Reviewed-by: Michael Kelley <mikelley@microsoft.com>

    \
     
     \ /
      Last update: 2019-02-20 17:11    [W:2.806 / U:0.084 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site