mysql_upgrade on fresh MySQL/MariaDB installation
According to Bogdan Kecman who worked at Oracle:


  mysql_upgrade checks whether the tables are at the latest version, if not - upgrades them
  and then marks them as upgraded. On a fresh install, even though tables are on the latest version, they are not marked. So, mysql_upgrade marks them. It does nothing else. To avoid scanning them
  again when mysql_upgrade runs.


Sorry for lousy translation.