#include <bits/stdc++.h>
using namespace std;
long long mod = 1000000007;
long long MOD = 998244353;
int inf = 1000001000;
long long INF = 2e18 + 17;
int main() {
  long long n, m;
  cin >> n >> m;
  vector<long long> a(n), b(m);
  for (int(i) = 0; (i) < (n); (i)++) cin >> a[i];
  for (int(i) = 0; (i) < (m); (i)++) cin >> b[i];
  sort((a).begin(), (a).end());
  sort((b).begin(), (b).end());
  if (a[n - 1] > b[0]) {
    cout << -1 << endl;
    return 0;
  }
  long long ans = 0;
  for (int(i) = 0; (i) < (n); (i)++) {
    ans += a[i] * m;
  }
  for (int(i) = 0; (i) < (m - 1); (i)++) {
    ans += (b[i + 1] - a[n - 1]);
  }
  if (a[n - 1] != b[0]) ans += b[0] - a[n - 2];
  cout << ans << endl;
}
