Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp248566pxf; Thu, 25 Mar 2021 03:13:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyiNWSU/a9tkCVeabdFsgKUzf/o5tft4V4CE2tcyvd/pgmWjEMpoy9DaqoQkeDdv+1RUzEG X-Received: by 2002:aa7:d686:: with SMTP id d6mr8280686edr.146.1616667234071; Thu, 25 Mar 2021 03:13:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616667234; cv=none; d=google.com; s=arc-20160816; b=A/NQLooQgyvZHGBlDBxFT3o8hxVWpUjvLDlYLpgJR/ZOVm7QQJal2r95f9rkiuhM0O Mc87pONI8OYKt0wYLaznD4yJuvIULqAkvf6xzAnln7VF7IjGMEKnB7eebFMX6Ltp5YzM NVxDyUBiH2SzyGX5KoCkqYysi1yEmk1l/PbH+BIe/bRGPAjFDG7MeAsrrggrbt+LyjgE csg7RVW7er0iuPKL6HnwdoXiUX+CQS8h0GyRsO7EBUBw7yGNoerrojyEhWTHX7CRcHx2 zASw9mOirIcLnjL5MfVAFJy9vmWpXI+vQDr5e9Czqfi/DaOjUGIIU3oq/P4NjgR59VZf MPdA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=kHwyM01WyqgWKCfJirzSlimPQ/XDp3q0BkoluHcHB6k=; b=ZpWwvzdttQzG51Kdw9/OABwARq/YZSFucO1UwICiEWYbV/UweOxHVCwA4vNE4drs20 UpTsuGDe6dm5CZBKwMptwEjrLi/7FUK6ibv0RramjMPX2TTXIx7dUuvG/feg407dT1Hm jSnpjATqLMG79xUw7kCmSoWMOqQh5RHXUpLtl3G7rpYXTIoGy+p86nTnBT17FnaCuzWh 2E0+QEOTuwQL9UTSW0GBoKCzNJQY5Mv2E7olgYSoqP49iVtiiUU3P0QAs1GW/YAmzyan WDtgsi1dpO6mqW4AdfcDIzdoRJ4w/Y1Hs1ErCZTQ1yJ2JjdFoy4PU8y2mHbDq4VfW3+1 j1Pw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=OZlZqvDS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f11si3816633ejr.284.2021.03.25.03.13.31; Thu, 25 Mar 2021 03:13:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=OZlZqvDS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229788AbhCYKJl (ORCPT + 99 others); Thu, 25 Mar 2021 06:09:41 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:46540 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230156AbhCYKJU (ORCPT ); Thu, 25 Mar 2021 06:09:20 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1616666959; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=kHwyM01WyqgWKCfJirzSlimPQ/XDp3q0BkoluHcHB6k=; b=OZlZqvDSASd+2XrkeMQs1YXRFqryjJKYedeQkbAhTi6YZh/wdRetle2swy5EuhIQ0VV0KF kdyPh7wYeDnGUzo+Taessuj/U30o27HE8ZSQqbGWxypqeSnfmyKsYb/0LS9ztK8tKjA5/A e0rPUU/vATfuTCPnEgEe8NAn+dZREuk= Received: from mail-wm1-f71.google.com (mail-wm1-f71.google.com [209.85.128.71]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-152-UjG4O7mNM724Pok55EDmrA-1; Thu, 25 Mar 2021 06:09:17 -0400 X-MC-Unique: UjG4O7mNM724Pok55EDmrA-1 Received: by mail-wm1-f71.google.com with SMTP id r18so1477340wmq.5 for ; Thu, 25 Mar 2021 03:09:17 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=kHwyM01WyqgWKCfJirzSlimPQ/XDp3q0BkoluHcHB6k=; b=LwinVrijHDMbiigUtzhA1A/taj1ajpj4y4NXCpRmOE8q0ZiLRwcZNZuT91WjvbpYKo SXFr+T6pZ7wygBzlEflOtyJm8JChKs6efmEcmkB0wiTnKVlXbUBcRY0T4kP5sgEpUktq wKe1ZqGA2M5a4YuocG0KVx8gzQ/vSPOA0SDkryePPIhwV+tTzfMCQ3bTAuxiOXSyCBOa z6Bh1NEzl8gL2/ui7PbQHvnFNWPfzuGGIU/i0KwZbPZamR6CsBz80+0ckQYUt46AtCnC SQDq4DeC7e1pQ7bxj2Wx2Yc2pNyznWHgTP8ZgZFhz9cb0/K4wL4HDy5McvpNQS7aNDZp +Eiw== X-Gm-Message-State: AOAM5302m+4o9uL7t0hw5YPHOR2cAtsV7bjOMYiH78/9evK+G98BCroa r0k/6XdKQk18gxi4DR9d4/HJRbnuoU4SY+Z3X7IvxhK8ePwG17IZnKLMtkh+p48X1N8gMX5UYgv vlUEcrgjIPxH93AvNUNd5M34s X-Received: by 2002:adf:a18a:: with SMTP id u10mr8019016wru.197.1616666956448; Thu, 25 Mar 2021 03:09:16 -0700 (PDT) X-Received: by 2002:adf:a18a:: with SMTP id u10mr8018978wru.197.1616666956222; Thu, 25 Mar 2021 03:09:16 -0700 (PDT) Received: from steredhat (host-79-34-249-199.business.telecomitalia.it. [79.34.249.199]) by smtp.gmail.com with ESMTPSA id s83sm6216998wms.16.2021.03.25.03.09.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 25 Mar 2021 03:09:15 -0700 (PDT) Date: Thu, 25 Mar 2021 11:09:13 +0100 From: Stefano Garzarella To: Arseny Krasnov Cc: Stefan Hajnoczi , "Michael S. Tsirkin" , Jason Wang , "David S. Miller" , Jakub Kicinski , Jorgen Hansen , Andra Paraschiv , Norbert Slusarek , Colin Ian King , Alexander Popov , kvm@vger.kernel.org, virtualization@lists.linux-foundation.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, stsp2@yandex.ru, oxffffaa@gmail.com Subject: Re: [RFC PATCH v7 13/22] virtio/vsock: add SEQPACKET receive logic Message-ID: <20210325100913.7rewuc4wn7zwtrqf@steredhat> References: <20210323130716.2459195-1-arseny.krasnov@kaspersky.com> <20210323131316.2461284-1-arseny.krasnov@kaspersky.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline In-Reply-To: <20210323131316.2461284-1-arseny.krasnov@kaspersky.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Mar 23, 2021 at 04:13:13PM +0300, Arseny Krasnov wrote: >This modifies current receive logic for SEQPACKET support: >1) Inserts 'SEQ_BEGIN' packet to socket's rx queue. >2) Inserts 'RW' packet to socket's rx queue, but without merging with > buffer of last packet in queue. >3) Performs check for packet and socket types on receive(if mismatch, > then reset connection). > >Signed-off-by: Arseny Krasnov >--- > v6 -> v7: > In 'virtio_transport_recv_pkt()', 'sock_put()' is added, when type of > received packet does not match to the type of socket. > > net/vmw_vsock/virtio_transport_common.c | 64 +++++++++++++++++-------- > 1 file changed, 45 insertions(+), 19 deletions(-) Reviewed-by: Stefano Garzarella