Received: by 2002:a05:7412:bbc7:b0:fc:a2b0:25d7 with SMTP id kh7csp1911846rdb; Sun, 4 Feb 2024 06:40:39 -0800 (PST) X-Google-Smtp-Source: AGHT+IHBxdT3TqXfGu/zP6FYCPs8ZgkH2W/bd2lNWRd1w8/8grYAkb3Q+9Z+/EfmYKJm52iiY5zi X-Received: by 2002:ac8:5cd0:0:b0:42a:b0b6:1ca6 with SMTP id s16-20020ac85cd0000000b0042ab0b61ca6mr5320748qta.64.1707057639030; Sun, 04 Feb 2024 06:40:39 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707057639; cv=pass; d=google.com; s=arc-20160816; b=n2Si4IgG2iJ/eXajkZ2oviSa2rIud7tYzUvQeVI82duJbgkdH8GhFJv6Z1s6w8/t8T TAjlmaNhfH0llWpf8dVPNi02zIJZInYMj3iXMmLwJagdTUJi+dy74oRCiLOmsHkQZB+r F7NvOh8tePTJ16wj199ULwuOXy41Y60O7EIkTXQ2Ze41lRnIZ9snD5dmzV15SqUf800O dRx/SHUwpdjK1hsZx2/GLl5IuowFei/IHmfauURanha6z9L0hKVshr+tS1puam338pqz ehgmtCgbXAcakBl71msxs0uNHjzuUsg2+W+cvy0a51tkANmRCCOsNmMeWGDBr1615Cu9 HqwQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:dkim-signature:message-id; bh=Y80CdJjL2kWlKWe2vMEsTFd6tb84k4wJ4sCbchotmMI=; fh=u+6TioQzlQ9NklrZeUlu73scQrfHHIe3lwFucpccjUU=; b=sa/aQCI/i0f7zv5WoIErTAWupNN24NGQMBMuUO7QfIQkS0zx1D74gy1vtX806meJE1 YinZxnPknGqeRI38J4ZqKyPLMDNJT9ohNg9Kc1ac7HEtjTfC/9e3ZSYmprx+wASEF/RG hS4wBeW6Ec/Tso9LvGQUA84JCgDn1MpHpE4zjpcN7zOOB+TiTy5aaTSu41KKjow8Wmha WeCyKbU3SN92WjncLlMGCmngogzQ8RYNYUQvb6ihQ+CbwZQyRiLFYm42Wh1B8ZkIOUN1 pElwy8Yxj1XDY96f6IAIVbBdz8CjG1dz64/ChZFXKL3XSMYnwfS0Kpg5MY1Ecmd/NIzA JEZw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=ApSE4Iec; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-51715-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-51715-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev X-Forwarded-Encrypted: i=1; AJvYcCXdlhkfeB7lZ9CtVikbUVzCSJxdXK7GsZ28J4epo9iAQZ0wVWOzSbR29Tt9BZDROJyOBwtsAg3UU9dMQ9ba82f3bF2B+A3HMqtPcea+qA== Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id bp31-20020a05622a1b9f00b0042a99face24si6454490qtb.795.2024.02.04.06.40.38 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 04 Feb 2024 06:40:39 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-51715-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=ApSE4Iec; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-51715-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-51715-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id B47BB1C2181B for ; Sun, 4 Feb 2024 14:40:38 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id F2F4F22F03; Sun, 4 Feb 2024 14:39:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="ApSE4Iec" Received: from out-187.mta1.migadu.com (out-187.mta1.migadu.com [95.215.58.187]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9308E225A9 for ; Sun, 4 Feb 2024 14:39:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=95.215.58.187 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707057596; cv=none; b=hTacTNqA0rVn3rAa65KZG3orql1Tow2n1SezV/10xpOyzUF7gOe1WcR82c61F2vo0QHej5b9ZuLs6z6pxcQjGVDzOePqRksYnCUovvWx5WKPsdOJqlPiVs/ghPlzOeuZSMEOZUXwMDZ3odilFL/02uBMejHMqVBG2/b/40mXU2Q= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707057596; c=relaxed/simple; bh=BL/x9orUY4Qx6/R/opi/OiQWicq/Bdzd8RXJYTHUSLw=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=Zw60G8Nkw3LM6O+XaxJQBwwtEo5r9DafQVWL15/Friom0MD7onYipHVhgM7xCI1BUGf6/fw6rpfNSLN7S+NCCN/kJzmzbx+R3tODqgCLogFCdvzAVt5Ll1dSRCBuQjTHZC3DVzw9byAeneV+YJ7F0qvSUi9zxxi+KARQ8DLxcKs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=ApSE4Iec; arc=none smtp.client-ip=95.215.58.187 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Message-ID: <6b88bdc3-37da-423f-a665-308ac519a256@linux.dev> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1707057591; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Y80CdJjL2kWlKWe2vMEsTFd6tb84k4wJ4sCbchotmMI=; b=ApSE4IecJ9joafKTB6l39BAFgHUNTXfhO+zwHvK0cYzw3KXqKm+QQ7mo6MuLlPqVWstEEm WWFxpRtF6mHexGCbpGKdOdF8uq421EBc0jz5dsGlQHnAlmVxU07jESxrbRVqFg3zpvl7bu RLyqjfTA+IF1u1PGlIBJlsI5SvYT/MQ= Date: Sun, 4 Feb 2024 14:39:46 +0000 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Subject: Re: [PATCH v5] ptp: ocp: add Adva timecard support Content-Language: en-US To: Sagi Maimon Cc: richardcochran@gmail.com, jonathan.lemon@gmail.com, vadfed@fb.com, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, kuba@kernel.org References: <20240117114350.3105-1-maimon.sagi@gmail.com> <8a6c5297-6e86-4f0d-a85e-1a93b2215d68@linux.dev> X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Vadim Fedorenko In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT On 04/02/2024 11:31, Sagi Maimon wrote: > Hi Vadim, > Sorry but I was on vacation for the last two weeks. > So What should I do now: > 1) Do you want me to set my changes into the main linux git tree: > git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git > and use use '[PATCH v6] ...' prefix > 2) Or > set my changes into the net-next git tree: > git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net-next.git > and use use '[PATCH net-next v6] ...' prefix Hi Sagi! Option 2 is the way to go. Thanks, Vadim > > BR, > Sagi > > On Wed, Jan 17, 2024 at 11:23 PM Vadim Fedorenko > wrote: >> >> On 17/01/2024 11:43, Sagi Maimon wrote: >>> Adding support for the Adva timecard. >>> The card uses different drivers to provide access to the >>> firmware SPI flash (Altera based). >>> Other parts of the code are the same and could be reused. >>> >> >> Hi Sagi, >> >> Thanks for adjusting the code. One signle still have to be >> adjusted, see comments below. And this is treated as net-next >> material, but net-next is closed now until merge window ends, >> you will have to submit new version next week. >> >> Please, also use '[PATCH net-next v6] ...' prefix for it. >> >>> Signed-off-by: Sagi Maimon >>> --- >>> Changes since version 4: >>> - alignment fix. >>> >> >> Please, preserve changes from all previous versions for next submissions. >> >>> drivers/ptp/ptp_ocp.c | 302 ++++++++++++++++++++++++++++++++++++++++-- >>> 1 file changed, 293 insertions(+), 9 deletions(-) >>> >> >> [ ..skip.. ] >> >>> @@ -2603,7 +2819,44 @@ ptp_ocp_art_board_init(struct ptp_ocp *bp, struct ocp_resource *r) >>> if (err) >>> return err; >>> >>> - return ptp_ocp_init_clock(bp); >>> + return ptp_ocp_init_clock(bp, r->extra); >>> +} >>> + >>> +/* ADVA specific board initializers; last "resource" registered. */ >>> +static int >>> +ptp_ocp_adva_board_init(struct ptp_ocp *bp, struct ocp_resource *r) >>> +{ >>> + int err; >>> + u32 version; >>> + >>> + bp->flash_start = 0xA00000; >>> + bp->eeprom_map = fb_eeprom_map; >>> + bp->sma_op = &ocp_adva_sma_op; >>> + >>> + version = ioread32(&bp->image->version); >>> + /* if lower 16 bits are empty, this is the fw loader. */ >>> + if ((version & 0xffff) == 0) { >>> + version = version >> 16; >>> + bp->fw_loader = true; >>> + } >>> + bp->fw_tag = 1; >> >> Please, use fw_tag = 3 here, other tags are for other vendors. >> >> Thanks, >> Vadim >> >>> + bp->fw_version = version & 0xffff; >>> + bp->fw_cap = OCP_CAP_BASIC | OCP_CAP_SIGNAL | OCP_CAP_FREQ; >>> + >>> + ptp_ocp_tod_init(bp); >>> + ptp_ocp_nmea_out_init(bp); >>> + ptp_ocp_signal_init(bp); >>> + >>