From patchwork Tue Apr 18 17:25:29 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johannes Thumshirn X-Patchwork-Id: 13215973 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id E91A1C6FD18 for ; Tue, 18 Apr 2023 17:26:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231782AbjDRR0f (ORCPT ); Tue, 18 Apr 2023 13:26:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34516 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232137AbjDRR0e (ORCPT ); Tue, 18 Apr 2023 13:26:34 -0400 Received: from mail-ej1-f41.google.com (mail-ej1-f41.google.com [209.85.218.41]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 64283B46B; Tue, 18 Apr 2023 10:26:24 -0700 (PDT) Received: by mail-ej1-f41.google.com with SMTP id xd13so41241247ejb.4; Tue, 18 Apr 2023 10:26:24 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681838783; x=1684430783; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=5v6TG43Q6Ul3Yw2SrINn59iVDlotZEfKLLIy9ug6DTU=; b=l1ZWGR7z3U3fRc3JoV5vFVLukZ2/5uPJx/XLiXruTNlfeod+iK/GZBB2MNbPW3fn6b oXnHXPzwuBiKHpK6Nh41m/x7tjOzWfRL6kwYbRyvCj4HsVrCYXXZpXFavDXbjtnwtKHw b78lYkEYOCClmTdNmR70iKodXMdtd4/oo//67Lzk2lYQwSNUkwi3T88tlNdNcIFz851N 9GR5bdLerrGrtxjNQMLuFQvPO6oXS8b9SPkfRyh3g03dJ1GqQI15NudKWiXtmcXtesLM zoEmQzDg8i4ZBxLTEX94T2HJBRKjPjPArDd7S3aIfkgLd+D8tG355MxojZClHJQ8rXrC FHlw== X-Gm-Message-State: AAQBX9fhgjv4f4zcU1CPh2S4/IK4ZN8kQiAmFH1wALUL2NExO6JsXvow t28ZLUWHAy6gGi1BBGSEakmwcmhhSg5aAg== X-Google-Smtp-Source: AKy350brxSJc/dhqblvXzlMmP/qxt6/dWWnpfUnLCUjfnoT3kZXls08JHtDG4ERRXK+1QQGvc7sK5g== X-Received: by 2002:a17:907:77d5:b0:94e:f738:514f with SMTP id kz21-20020a17090777d500b0094ef738514fmr11584269ejc.13.1681838782686; Tue, 18 Apr 2023 10:26:22 -0700 (PDT) Received: from localhost.localdomain (aftr-62-216-205-204.dynamic.mnet-online.de. [62.216.205.204]) by smtp.googlemail.com with ESMTPSA id j23-20020a1709066c1700b0095342bfb701sm63259ejr.16.2023.04.18.10.26.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 18 Apr 2023 10:26:21 -0700 (PDT) From: Johannes Thumshirn To: Wim Van Sebroeck , Guenter Roeck Cc: linux-watchdog@vger.kernel.org, linux-kernel@vger.kernel.org, Johannes Thumshirn Subject: [PATCH 0/2] watchdog: fixes for menz069_wdt driver Date: Tue, 18 Apr 2023 19:25:29 +0200 Message-Id: <20230418172531.177349-1-jth@kernel.org> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-watchdog@vger.kernel.org While testing the Qemu emulation of the menz069_wdt watchdog core, I've found two issues in the kernel driver. On is a NULL pointer dereference, because the driver can't access it's private data and one is a wrong register read resulting in incorrect timeout values being set. Johannes Thumshirn (2): watchdog: menz069_wdt: fix watchdog initialisation watchdog: menz069_wdt: fix timeout setting drivers/watchdog/menz69_wdt.c | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-)